home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload Trio 2
/
Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO
/
dir37
/
mxmenu.zip
/
MARXMENU.DOC
< prev
next >
Wrap
Text File
|
1993-07-15
|
522KB
|
15,410 lines
===================================================================
<*> Computer Tyme MarxMenu <*>
Reference Manual
Copyright 1989 - 1993 by Marc Perkel
All Rights Reserved * Version 2.44 * Release Date: 07-08-93
Computer Tyme * 411 North Sherman Suite 300 * Springfield, MO 65802
(417) 866-1222 voice * (417) 866-1665 bbs
Fax: (417) 866-0135
CompuServe: 71333,427
MHS: Marc @ CTyme
Internet: Marc @ CTyme.MHS.Compuserve.com
===================================================================
Computer Tyme * MarxMenu * Table of Contents Page #1
-----------------------------------------------------------------
Copyright .............................................. 1
License Agreement ...................................... 1
MarxMenu Trademarks .................................... 3
Technical Support ...................................... 3
Installation ........................................... 4
Getting Started Quick .................................. 6
Use MarxHelp ........................................... 8
Common Questions and Mistakes .......................... 8
MarxMenu Features ...................................... 12
Overview of the MarxMenu System ........................ 13
What MarxMenu Does ..................................... 15
The MARX.BAT File ...................................... 15
DROPTO.BAT ............................................. 18
Support for early DOS versions ......................... 19
About Environment Variables ............................ 20
Dealing with Multiple DOS Shells ....................... 21
MarxMenu and TSR Control ............................... 22
Network Users .......................................... 22
Network Menu Strategy .................................. 23
Using TRUENAME on Networks ............................. 24
Novell Users ........................................... 24
The Novell Menu Translator ............................. 25
Logging out under Menu Control ......................... 26
Logging in with MarxMenu ............................... 27
Using Novell's Login ................................... 27
The CONFIG.SYS File .................................... 28
The AUTOEXEC.BAT File .................................. 29
Using a Menu File to Log In ............................ 30
Novell Search Drives ................................... 31
Novell Drive Mapping Tricks ............................ 32
Setting File Attributes ................................ 32
Novell Semaphores ...................................... 33
Using Semaphores for Software Metering ................. 34
NetWare MHS & MarxMenu ................................. 34
Upgrading MarxMenu ..................................... 35
Customizing MarxMenu Sample Files ...................... 36
Menu Analysis .......................................... 37
Onkey Statements ....................................... 37
Popup Menus ............................................ 39
The Console ............................................ 40
Repositioning the Top Window ........................... 40
Mouse Support .......................................... 41
Starting off the Easy Way .............................. 41
About Variables ........................................ 41
Numeric Variables ...................................... 42
Boolean Variables ...................................... 43
String Variables ....................................... 43
Real Numbers ........................................... 43
Local Variables ........................................ 44
Dates .................................................. 44
Passing Parameters to Procedures ....................... 45
About Constants ........................................ 46
About Arrays ........................................... 47
About Qualifiers ....................................... 47
Pointer Variables ...................................... 49
Computer Tyme * MarxMenu * Table of Contents Page #2
-----------------------------------------------------------------
Comments in Menu Files ................................. 49
The MarxMenu Compiler .................................. 50
MarxMenu Language Rules ................................ 50
Compiler Compatibility ................................. 51
A word about DOS versions .............................. 51
A word about BUGS ...................................... 52
Tips From the Master ................................... 52
Computers do Simple Tasks .............................. 53
Complex Tasks are made of Simple Tasks ................. 53
Learning Good Programming Habits ....................... 54
Use Long Names ......................................... 54
Use Comments Liberally ................................. 56
Indent Your code ....................................... 57
For Duplicate Tasks, Use Procedures .................... 57
Don't Program Yourself into a Corner ................... 58
For the POWER User ..................................... 58
Where MarxMenu is Heading .............................. 59
A word to Writers and Reviewers ........................ 60
Security Issues ........................................ 61
Keeping Users in the Menu .............................. 62
Using BREAK.SYS ........................................ 62
Using the SHELL= Command ............................... 63
Conditional Statements ................................. 64
Environment Variables used by MarxMenu ................. 65
MarxMenu DataBase Functions ............................ 66
Additional Information ................................. 67
Computer Tyme on Compuserve ............................ 67
MarxMenu Commands ...................................... 68
| ...................................................... 69
( ...................................................... 69
) ...................................................... 69
* ...................................................... 69
+ ...................................................... 70
- ...................................................... 70
/ ...................................................... 70
< ...................................................... 70
<= ..................................................... 71
<> ..................................................... 71
= ...................................................... 71
> ...................................................... 71
>= ..................................................... 72
Abs .................................................... 72
Actual ................................................. 72
Alias .................................................. 72
AllowAbort ............................................. 73
AllowEsc ............................................... 73
And .................................................... 73
AnsiWindows ............................................ 73
AppendArray ............................................ 74
ApplicationMemory ...................................... 74
ArcTan ................................................. 74
ArrayInsert ............................................ 74
AssignList ............................................. 75
BadDate ................................................ 75
Bat .................................................... 75
Computer Tyme * MarxMenu * Table of Contents Page #3
-----------------------------------------------------------------
BatFileName ............................................ 76
BigShadow .............................................. 76
BinString .............................................. 76
BiosDate ............................................... 76
Blanked ................................................ 76
BlankMessage ........................................... 77
BlankScreenProgram ..................................... 77
BlankTime .............................................. 78
Blink .................................................. 78
BlockBox ............................................... 79
BootDrive .............................................. 79
BoxBorderColor ......................................... 79
BoxHeader .............................................. 79
BoxHeaderColor ......................................... 80
BoxHeaderLeft .......................................... 80
BoxHeaderRight ......................................... 80
BoxFooter .............................................. 81
BoxFooterLeft .......................................... 81
BoxFooterRight ......................................... 81
BoxInsideColor ......................................... 82
Break .................................................. 82
BrightBackground ....................................... 82
BtrvAbortTransaction ................................... 83
BtrvBeginTransaction ................................... 83
BtrvClearOwner ......................................... 83
BtrvClose .............................................. 83
BtrvCreate ............................................. 84
BtrvDelete ............................................. 86
BtrvEndTransaction ..................................... 86
BtrvGetEqual ........................................... 87
BtrvGetFirst ........................................... 87
BtrvGetGreater ......................................... 88
BtrvGetGreaterOrEqu .................................... 88
BtrvGetLast ............................................ 88
BtrvGetLess ............................................ 89
BtrvGetLessOrEqu ....................................... 90
BtrvGetNext ............................................ 90
BtrvGetPrev ............................................ 90
BtrvIndexes ............................................ 91
BtrvInsert ............................................. 91
BtrvOpen ............................................... 91
BtrvPageSize ........................................... 92
BtrvRecLen ............................................. 92
BtrvRecords ............................................ 92
BtrvReset .............................................. 92
BtrvResult ............................................. 93
BtrvResultMessage ...................................... 94
BtrvSetOwner ........................................... 94
BtrvStepFirst .......................................... 94
BtrvStepLast ........................................... 95
BtrvStepNext ........................................... 95
BtrvStepPrev ........................................... 96
BtrvStop ............................................... 96
BtrvUnUsedPages ........................................ 96
BtrvUpdate ............................................. 97
Computer Tyme * MarxMenu * Table of Contents Page #4
-----------------------------------------------------------------
BtrvVersion ............................................ 97
BuildPath .............................................. 97
CancelListEntry ........................................ 98
CapFirstChar ........................................... 98
CapsColor .............................................. 98
CapsLock ............................................... 99
Chain .................................................. 99
Char ................................................... 99
ChDir .................................................. 99
CleanFileName .......................................... 100
ClearKbdBuffer ......................................... 100
ClearKeyEvents ......................................... 100
ClearLine .............................................. 100
ClearScreen ............................................ 101
ClearScreenFirst ....................................... 101
ClearScreenOnExit ...................................... 101
ClockColor ............................................. 101
ClockMode .............................................. 102
ClockPos ............................................... 102
ClosePrinter ........................................... 103
ClusterSize ............................................ 103
CmdLine ................................................ 103
CMOS ................................................... 104
ColdBoot ............................................... 104
ColorScreen ............................................ 104
ComBaud ................................................ 104
ComBlockErrors ......................................... 105
ComBlockNumber ......................................... 105
ComBlockSize ........................................... 105
ComBreakReceived ....................................... 105
ComBytesRemaining ...................................... 105
ComBytesTransferred .................................... 106
ComCD .................................................. 106
ComCDAbort ............................................. 106
ComCharReady ........................................... 106
ComDataBits ............................................ 106
ComDonePort ............................................ 107
ComDrainSendBuffer ..................................... 107
ComDTR ................................................. 107
ComEchoRecChar ......................................... 107
ComEchoSendChar ........................................ 107
ComEmptyRecBuffer ...................................... 108
ComEmptySendBuffer ..................................... 108
ComErrorLimit .......................................... 108
ComFileName ............................................ 108
ComFileSize ............................................ 108
ComInitPort ............................................ 109
ComLastChar ............................................ 109
ComLastLine ............................................ 109
ComNewLineProgram ...................................... 109
ComParity .............................................. 110
ComPort ................................................ 110
ComProtocol ............................................ 110
ComReadChar ............................................ 110
ComReadln .............................................. 111
Computer Tyme * MarxMenu * Table of Contents Page #5
-----------------------------------------------------------------
ComReadTimeout ......................................... 111
ComRec1kXmodem ......................................... 111
ComRecKermit ........................................... 111
ComRecXmodem ........................................... 112
ComRecYmodem ........................................... 112
ComRecYmodemG .......................................... 112
ComRecZmodem ........................................... 112
ComResult .............................................. 113
ComRI .................................................. 113
ComRTS ................................................. 113
ComSendBreak ........................................... 113
ComSend1kXmodem ........................................ 113
ComSendKermit .......................................... 114
ComSendXmodem .......................................... 114
ComSendYmodem .......................................... 114
ComSendYmodemG ......................................... 115
ComSendZmodem .......................................... 115
ComStopBits ............................................ 115
ComStripHighBit ........................................ 116
ComThisLine ............................................ 116
ComTimeout ............................................. 116
ComTotalErrors ......................................... 116
ComUseInt14 ............................................ 117
ComUseUart ............................................. 117
ComWatchCD ............................................. 117
ComWrite ............................................... 117
ComWriteln ............................................. 118
ComWriteTimeout ........................................ 118
ComXmitAbortProgram .................................... 118
ComXmitEnding .......................................... 118
ComXmitStarting ........................................ 119
ComXmitStatusProgram ................................... 119
Comment ................................................ 119
Console ................................................ 119
ConsoleBorderColor ..................................... 120
ConsoleHeaderColor ..................................... 120
ConsoleInsideColor ..................................... 120
ConsolePos ............................................. 120
Const .................................................. 120
Cos .................................................... 121
CountryCode ............................................ 121
CpuClass ............................................... 121
CpuName ................................................ 121
CurrencySymbol ......................................... 122
CurrentDirectory ....................................... 122
CurrentEnvironment ..................................... 122
CurrentWindow .......................................... 122
Cursor ................................................. 122
CustomBox .............................................. 123
DateSeparator .......................................... 123
DateString ............................................. 123
Day .................................................... 123
DayOf .................................................. 123
DayOfWeek .............................................. 124
DayOfWeekOf ............................................ 124
Computer Tyme * MarxMenu * Table of Contents Page #6
-----------------------------------------------------------------
DecimalSeparator ....................................... 124
Delete ................................................. 124
DelFile ................................................ 125
Devices ................................................ 125
DirectoriesOnly ........................................ 126
DisplayType ............................................ 126
DiskType ............................................... 126
Dispose ................................................ 127
DosVersion ............................................. 127
DosVersionString ....................................... 127
DosWindow .............................................. 128
DoubleLineBox .......................................... 128
DPMIInstalled .......................................... 128
DPMIVersion ............................................ 128
DrawBox ................................................ 128
Drives ................................................. 129
DriveType .............................................. 129
DvAppNumber ............................................ 129
DvFrame ................................................ 130
DvFreeze ............................................... 130
DvHide ................................................. 130
DvKillTask ............................................. 130
DvLastHandle ........................................... 130
DvLoaded ............................................... 130
DvMoveWindow ........................................... 131
DvMyHandle ............................................. 131
DvPifExecute ........................................... 131
DvResizeWindow ......................................... 131
DvSetBottom ............................................ 131
DvSetTop ............................................... 132
DvUnFreeze ............................................. 132
DvUnHide ............................................... 132
Else ................................................... 132
ElseIf ................................................. 133
EmsInstalled ........................................... 133
EmsVersion ............................................. 133
EndComment ............................................. 133
Endif .................................................. 134
EndLoop ................................................ 134
EndOfFile .............................................. 134
EndProc ................................................ 135
EndWhile ............................................... 135
EnvFree ................................................ 135
EnvSize ................................................ 135
EraseTopWindow ......................................... 135
EraseWindow ............................................ 136
Execute ................................................ 136
ExistDir ............................................... 137
ExistFile .............................................. 137
ExistOnPath ............................................ 138
ExitCode ............................................... 138
ExitMenu ............................................... 138
Exp .................................................... 138
Explode ................................................ 138
ExplodeDelay ........................................... 139
Computer Tyme * MarxMenu * Table of Contents Page #7
-----------------------------------------------------------------
Extension .............................................. 139
FileAppend ............................................. 139
FileAssign ............................................. 139
FileAttr ............................................... 140
FileClose .............................................. 140
FileCreate ............................................. 140
FileDate ............................................... 141
FileFlush .............................................. 141
FileLog ................................................ 141
FileOpen ............................................... 141
FilePart ............................................... 142
FilePos ................................................ 142
FileReadln ............................................. 142
FileRename ............................................. 142
FileResult ............................................. 142
FileSeek ............................................... 143
FileSize ............................................... 143
FileTime ............................................... 143
FileWrite .............................................. 143
FileWriteln ............................................ 143
FixPath ................................................ 144
Floppies ............................................... 144
ForceExplosion ......................................... 144
ForceExtension ......................................... 144
Fraction ............................................... 144
FreeDiskSpace .......................................... 144
FreeEms ................................................ 145
FreeMem ................................................ 145
FreeMemory ............................................. 145
FullLineReturn ......................................... 145
GetMem ................................................. 145
GotoXY ................................................. 146
HexString .............................................. 146
HiddenAndSystem ........................................ 146
HighWord ............................................... 146
Hour ................................................... 147
HourOf ................................................. 147
Hundredth .............................................. 147
IdleProgram ............................................ 147
If ..................................................... 148
InactiveBox ............................................ 149
InactiveBoxColor ....................................... 149
InactiveShadow ......................................... 149
Include ................................................ 149
IncludeDirectories ..................................... 150
InFile ................................................. 150
InMem .................................................. 151
InputBlankChar ......................................... 151
InputLength ............................................ 151
InputString ............................................ 152
Insert ................................................. 152
InsertMode ............................................. 152
Int .................................................... 152
Integer ................................................ 153
Intr ................................................... 153
Computer Tyme * MarxMenu * Table of Contents Page #8
-----------------------------------------------------------------
InverseColor ........................................... 153
InvertString ........................................... 153
IpxLoaded .............................................. 153
Jump ................................................... 154
KbdReady ............................................... 154
KeyEvent ............................................... 154
KeyFromMouse ........................................... 154
KeySave ................................................ 155
KillMusic .............................................. 155
LastDrive .............................................. 155
LastKey ................................................ 155
Left ................................................... 155
Length ................................................. 156
Ln ..................................................... 156
Loc .................................................... 156
Local .................................................. 157
LockWord ............................................... 158
Logoff ................................................. 158
LogoffTime ............................................. 159
Logout ................................................. 159
LongestLine ............................................ 160
Loop ................................................... 160
LoopIndex .............................................. 161
LoopLevel .............................................. 161
LoopLimit .............................................. 161
LowerCase .............................................. 162
LowWord ................................................ 162
MachineName ............................................ 162
MakeListEntry .......................................... 162
MarxVersion ............................................ 163
MasterEnvironment ...................................... 163
Max .................................................... 163
MatrixInvert ........................................... 163
McpClass ............................................... 164
McpName ................................................ 164
Mem .................................................... 164
MemL ................................................... 164
MemSize ................................................ 165
MemW ................................................... 165
MemoryLoc .............................................. 165
MenuFileName ........................................... 165
MenuKeyBuffer .......................................... 165
MhsDirectory ........................................... 166
MhsMailDirectory ....................................... 166
MhsReadFile ............................................ 166
MhsSendDirectory ....................................... 167
MhsUserDirectory ....................................... 167
Mid .................................................... 167
Min .................................................... 167
MinorDosVersion ........................................ 168
Minute ................................................. 168
MinuteOf ............................................... 168
MkDir .................................................. 168
Mod .................................................... 168
ModifyPath ............................................. 169
Computer Tyme * MarxMenu * Table of Contents Page #9
-----------------------------------------------------------------
Month .................................................. 169
MonthOf ................................................ 169
Mouse .................................................. 169
MouseHorizontal ........................................ 170
MouseIRQ ............................................... 170
MouseType .............................................. 170
MouseVersion ........................................... 170
MouseVertical .......................................... 170
MoveWindow ............................................. 171
MsDos .................................................. 171
MxCmd .................................................. 171
NamePart ............................................... 172
NetworkVersion ......................................... 172
NextWord ............................................... 172
Nil .................................................... 172
NoBoxBorder ............................................ 172
NoExit ................................................. 172
Not .................................................... 173
NotesLeft .............................................. 173
NotesPlayed ............................................ 173
NovAccountExpDate ...................................... 173
NovAddUserToGroup ...................................... 173
NovAddToSet ............................................ 174
NovAttach .............................................. 174
NovAttachedServers ..................................... 174
NovAutoDetach .......................................... 175
NovBinderyAccess ....................................... 175
NovBroadcastMode ....................................... 175
NovCaptureCopies ....................................... 175
NovCaptureFF ........................................... 176
NovCaptureFile ......................................... 176
NovCaptureFlush ........................................ 176
NovCaptureForm ......................................... 176
NovCaptureQueue ........................................ 177
NovCaptureReset ........................................ 177
NovCaptureSetup ........................................ 177
NovCaptureTabSize ...................................... 177
NovCaptureTimeOut ...................................... 178
NovCaptureUseBanner .................................... 178
NovChangePassword ...................................... 178
NovChangeObjPassword ................................... 178
NovCleanVolumeName ..................................... 179
NovClearConnection ..................................... 179
NovCloseBindery ........................................ 179
NovCloseSemaphore ...................................... 179
NovConnection .......................................... 179
NovConnectionsInUse .................................... 180
NovConsoleOperator ..................................... 180
NovCreateObject ........................................ 180
NovCreateProperty ...................................... 182
NovDefaultServer ....................................... 182
NovDeleteFromSet ....................................... 182
NovDeleteObject ........................................ 183
NovDeleteProperty ...................................... 183
NovDetach .............................................. 183
Computer Tyme * MarxMenu * Table of Contents Page #10
-----------------------------------------------------------------
NovDownServer .......................................... 183
NovEndCapture .......................................... 184
NovForceDownServer ..................................... 184
NovFreeDirSlots ........................................ 184
NovFreeVolumeSpace ..................................... 184
NovFullName ............................................ 184
NovGetConnections ...................................... 185
NovGetMessage .......................................... 185
NovGraceLoginReset ..................................... 185
NovGraceLogins ......................................... 186
NovGroupMembers ........................................ 186
NovGroups .............................................. 186
NovInGroup ............................................. 187
NovLastLoginDate ....................................... 187
NovLogin ............................................... 187
NovLoginName ........................................... 188
NovLogout .............................................. 188
NovMapDrive ............................................ 188
NovMapRoot ............................................. 188
NovMaxConnections ...................................... 189
NovMinPasswordLength ................................... 189
NovMyLoginName ......................................... 189
NovMyPassword .......................................... 189
NovMyPrintQueues ....................................... 190
NovObjectID ............................................ 190
NovObjects ............................................. 190
NovObjectSecurity ...................................... 191
NovOpenBindery ......................................... 191
NovOpenSemaphore ....................................... 191
NovPasswordExpDate ..................................... 192
NovPreferredServer ..................................... 192
NovPrimaryServer ....................................... 192
NovPrintQueues ......................................... 192
NovPropertySecurity .................................... 193
NovPropertyValues ...................................... 193
NovReadGroups .......................................... 194
NovReadSecurityEquals .................................. 194
NovRemoveUserFromGroup ................................. 194
NovRenameObject ........................................ 195
NovResult .............................................. 195
NovScanProperties ...................................... 195
NovScanTrusteePaths .................................... 195
NovSecurityEquals ...................................... 196
NovSemaphoreTimeout .................................... 196
NovSemaphoreUsers ...................................... 196
NovSemaphoreValue ...................................... 196
NovSendMessage ......................................... 197
NovServerLogin ......................................... 197
NovServers ............................................. 197
NovServerTime .......................................... 197
NovSetPreferredServer .................................. 198
NovSetPrimaryServer .................................... 198
NovSetProperty ......................................... 198
NovShellVersion ........................................ 199
NovSignalSemaphore ..................................... 199
Computer Tyme * MarxMenu * Table of Contents Page #11
-----------------------------------------------------------------
NovStaticObject ........................................ 199
NovStaticProperty ...................................... 199
NovStationAddress ...................................... 199
NovTotalDirSlots ....................................... 200
NovTotalVolumeSpace .................................... 200
NovUsedVolumeSpace ..................................... 200
NovUserInGroup ......................................... 201
NovUsers ............................................... 201
NovUsersLoggedIn ....................................... 201
NovVersionNumber ....................................... 202
NovVolumeNumber ........................................ 202
NovVolumes ............................................. 202
NovWaitOnSemaphore ..................................... 202
NovWritePropValue ...................................... 202
NumberOfElements ....................................... 203
Now .................................................... 203
NumericOnly ............................................ 203
NumLock ................................................ 203
Offset ................................................. 204
OnKey .................................................. 204
OnScreenOnly ........................................... 206
OpenPrinter ............................................ 206
OptionSwitch ........................................... 206
Or ..................................................... 206
Ord .................................................... 207
OutFile ................................................ 207
OverKey ................................................ 207
Overlay ................................................ 207
Overlayed .............................................. 208
PadLeft ................................................ 208
PadRight ............................................... 208
ParallelPorts .......................................... 208
ParamStr ............................................... 209
ParentEnvironment ...................................... 209
Password ............................................... 209
PathPart ............................................... 209
PauseAfterExecute ...................................... 210
PcType ................................................. 210
Pi ..................................................... 210
PickFile ............................................... 210
PickMany ............................................... 211
PickManyPositions ...................................... 211
PickOne ................................................ 212
PickPosition ........................................... 212
Port ................................................... 212
Pos .................................................... 212
PosInList .............................................. 213
PosInSortedList ........................................ 213
Power .................................................. 213
Pred ................................................... 213
Print .................................................. 214
PrinterName ............................................ 214
Println ................................................ 214
PrintScreen ............................................ 214
Procedure .............................................. 214
Computer Tyme * MarxMenu * Table of Contents Page #12
-----------------------------------------------------------------
PullMenu ............................................... 216
Qualifier .............................................. 216
QualVal ................................................ 216
Random ................................................. 217
ReadAscTextFile ........................................ 217
ReadDirectory .......................................... 217
ReadEnv ................................................ 218
ReadEnvironment ........................................ 218
ReadFileBlock .......................................... 219
ReadKey ................................................ 219
Readln ................................................. 220
ReadlnAsc .............................................. 220
ReadSqDirectory ........................................ 220
ReadTextFile ........................................... 221
Real ................................................... 222
Reboot ................................................. 222
ReleaseDate ............................................ 222
Repeat ................................................. 222
ResizeWindow ........................................... 223
Return ................................................. 223
ReturnCode ............................................. 223
Right .................................................. 224
RmDir .................................................. 224
RollWindow ............................................. 224
Run .................................................... 225
SavePosition ........................................... 225
ScreenHeight ........................................... 226
ScreenWidth ............................................ 226
ScrollLock ............................................. 226
ScrollMove ............................................. 226
Second ................................................. 226
SecondOf ............................................... 227
Security ............................................... 227
Segment ................................................ 227
SelectPath ............................................. 227
SerialNumber ........................................... 228
SerialPorts ............................................ 228
Set .................................................... 228
SetArraySize ........................................... 228
SetEnv ................................................. 228
SetTimerTask ........................................... 229
SetTopWindow ........................................... 229
SetWindowUnder ......................................... 230
Shadow ................................................. 230
ShadowColor ............................................ 230
ShadowPosition ......................................... 230
Shared ................................................. 231
ShellEnvironment ....................................... 231
Shl .................................................... 231
Shr .................................................... 231
Sin .................................................... 232
SingleLineBox .......................................... 232
SmallShadow ............................................ 232
SortArray .............................................. 232
SortArrayLinked ........................................ 233
Computer Tyme * MarxMenu * Table of Contents Page #13
-----------------------------------------------------------------
Sound .................................................. 233
SplitPath .............................................. 233
SpxFreeConnections ..................................... 234
SpxLoaded .............................................. 234
SpxMaxConnections ...................................... 234
Sqr .................................................... 234
StandardIO ............................................. 234
Str .................................................... 235
StuffAKey .............................................. 235
StuffKBD ............................................... 235
StuffKeyboardNow ....................................... 235
Succ ................................................... 235
Suggest ................................................ 236
TaskNumber ............................................. 236
TextBackground ......................................... 236
TextColor .............................................. 236
TextMode ............................................... 237
TextPos ................................................ 237
TextSeek ............................................... 237
Then ................................................... 237
TimeOf ................................................. 237
Timer .................................................. 238
TimeSeparator .......................................... 238
TimeString ............................................. 238
TMaxActiveTasks ........................................ 238
TMaxCreateTask ......................................... 239
TMaxCut ................................................ 239
TMaxDeleteTask ......................................... 239
TMaxDirectSwitching .................................... 239
TMaxEMSMemLim .......................................... 239
TMaxGetPasteBuffer ..................................... 240
TMaxInstalled .......................................... 240
TMaxMaxTasks ........................................... 240
TMaxNameTask ........................................... 240
TMaxPaste .............................................. 240
TMaxReadTaskInfo ....................................... 241
TMaxResult ............................................. 241
TMaxReturnCount ........................................ 241
TMaxSetPasteBuffer ..................................... 241
TMaxSwitchTasks ........................................ 242
TMaxSwitchToManager .................................... 242
TMaxTakeOver ........................................... 242
TMaxTaskOpenFiles ...................................... 242
TMaxThisTask ........................................... 242
TMaxVersion ............................................ 243
Today .................................................. 243
Tomorrow ............................................... 243
Tone ................................................... 243
TotalDiskSpace ......................................... 243
TotalEms ............................................... 244
Trim ................................................... 244
TrimInputString ........................................ 244
TrueName ............................................... 244
TSRs ................................................... 245
UnBlank ................................................ 245
Computer Tyme * MarxMenu * Table of Contents Page #14
-----------------------------------------------------------------
UniqueFileName ......................................... 246
Until .................................................. 246
UpperCase .............................................. 246
UpperCaseOnly .......................................... 246
UseArrows .............................................. 247
UseCommand ............................................. 247
UsedDiskSpace .......................................... 247
UseNovPassword ......................................... 248
Value .................................................. 248
Var .................................................... 248
VarType ................................................ 248
VCPIInstalled .......................................... 249
VCPIVersion ............................................ 249
VideoMode .............................................. 249
VideoPage .............................................. 249
ViewArray .............................................. 249
ViewTextFile ........................................... 250
VinCheckService ........................................ 250
VinesInt ............................................... 251
VinesLoaded ............................................ 251
VinUserName ............................................ 251
VinSerialNumber ........................................ 251
Volume ................................................. 251
VT100mode .............................................. 251
Wait ................................................... 252
WaitOrKbdReady ......................................... 252
WhereX ................................................. 252
WhereXAbs .............................................. 252
WhereY ................................................. 252
WhereYAbs .............................................. 252
While .................................................. 253
WholeFileNames ......................................... 253
Window ................................................. 253
WindowHeight ........................................... 253
WindowWidth ............................................ 254
WinX ................................................... 254
WinY ................................................... 254
Within ................................................. 254
WordStarKeys ........................................... 254
WorkString ............................................. 255
Write .................................................. 255
WriteAscTextFile ....................................... 255
WriteCenter ............................................ 255
WriteError ............................................. 255
WriteFileBlock ......................................... 255
Writeln ................................................ 256
WritelnAsc ............................................. 256
WritelnError ........................................... 256
WriteTextFile .......................................... 256
WriteVertical .......................................... 257
XmsInstalled ........................................... 257
XmsVersion ............................................. 257
Xor .................................................... 257
Year ................................................... 258
YearOf ................................................. 258
Computer Tyme * MarxMenu * Table of Contents Page #15
-----------------------------------------------------------------
String Constants ....................................... 258
Time and Date Constants ................................ 259
Video Constants ........................................ 259
Color Constants ........................................ 259
Boolean Constants ...................................... 260
Computer Tyme * MarxMenu * Users Manual Page #1
-----------------------------------------------------------------
COPYRIGHT
This manual is copyrighted material and all rights are reserved.
MarxMenu is a programming language which describes to the computer what
it is supposed to do. Even though some of the individual words in
MarxMenu are used in other programming languages, I claim a copyright on
the collection of words which make up the MarxMenu language. I therefore
consider it an infringement of my Copyright to create a software product
which uses the MarxMenu language, or translates MarxMenu source code,
without purchasing a license to do so.
The combinations of definitions of commands in this manual constitute a
copyrighted work. Any publication which describes a computer language
for which the MarxMenu command set is a subset is a violation of the
copyright of this software and this written manual.
You agree not to translate, modify, disassemble, decompile, or reverse
engineer any of our programs. This program contains proprietary memory
variable and array addressing algorithms which are considered to be
trade secrets and our property. These algorithms include, but are not
limited to, the MarxMenu variable addressing structures and concepts as
well as those data structures MarxMenu uses in it's database features.
Our claim of intellectual property and trade secrets is not limited to
the actual implementation of code, but extends to the MarxMenu source
language and the user interface language constructs that are unique to
this software product.
In addition to intellectual property rights protected by law, your use
of this product constitutes your acceptance of these terms and
conditions and your acknowledgement of the above rights.
In other words, don't try to clone MarxMenu.
LICENSE AGREEMENT
You are licensed to use this program on a single CPU or workstation. If
you are running on a network, you are required to license a separate
copy for each workstation or a file server license for each file server.
If you are running on a multiuser operating system such as Concurrent
DOS, you are required to license a copy for each workstation. Everyone
who uses this menu, must license a copy unless several people share the
same workstation.
This software is licensed and not sold. The license begins when Computer
Tyme receives payment in full. You may not transfer, sublease or rent
this software without the written consent of Computer Tyme. You are not
allowed to distribute MarxMenu in runtime form with software you've
developed unless it is in combination with a paid-for copy of MarxMenu,
or you have made special arrangements in writing with Computer Tyme to
do so.
Computer Tyme * MarxMenu * Users Manual Page #2
-----------------------------------------------------------------
Network licenses include a license to use this software on a local hard
disk in stand-alone mode provided that the computer is part of a
computer network. Computers that are not connected to the network are
not covered. The network license also includes a license for a single
network supervisor to use the software at home for menu development and
testing.
Site licenses require the payment of an annual renewal and support fee.
If the annual renewal fee is not paid within six months of the due date
then the site license status is considered expired and terminated.
The warranty is limited to the diskettes to be machine readable for a
period of 180 days after purchase. Although we try hard to write perfect
software that has no bugs, we do not guarantee that. This software is
provided AS IS. We also do not guarantee that this product is fit for
any particular purpose and we are not liable for any damages that might
occur from use of this product. We reserve the right to make changes to
any and all parts of this software at any time without obligation to
notify any person or entity of such changes. This agreement is governed
by the laws of the State of Missouri.
Use of this product constitutes your acceptance of the terms and
conditions of this license and of my copyright and your agreement to
abide by these terms and conditions. We may terminate this license at
any time if you are in breach of any of its terms or conditions.
We reserve the right to conduct or have conducted audits to verify your
compliance with this agreement.
I would like to thank the following people for making this product
possible:
Joe Smith, and Kevin Moore for helping write this manual. My wife Vicki
for being good to me and helping with revisions and editing.
The Computer Tyme staff for being the best employees in the world.
Borland International for writing Turbo Pascal and keeping it bug free
and well supported.
TurboPower Software for their very powerful extensions to Turbo Pascal
and their well written, well supported product.
All users who actually paid for this product so that we may continue to
eat.
Those of you who have pointed out bugs and made suggestions to improve
our product.
Computer Tyme * MarxMenu * Users Manual Page #3
-----------------------------------------------------------------
MARXMENU TRADEMARKS
MarxMenu is a registered trademark of Computer Tyme. DOS ToolBox,
Directory Master, MarxBase, MarxCom, anything that begins with the word
Marx, and The Network Survival Kit are trademarks of Computer Tyme.
Lotus is a registered trademark of Lotus Development.
Wordstar is a registered trademark of MicroPro International.
Smart Software is a trademark of Informix.
MS-DOS and MS-Windows are trademarks of Microsoft.
Turbo Pascal is a trademark of Borland International.
OPRO and TPRO are trademarks of TurboPower Software.
Netware, Novell and Btrieve are trademarks of Novell.
Concurrent DOS and DR-DOS are trademarks of Novell.
DesqView and QEMM are trademarks of Quarterdeck.
IBM and OS/2 are trademarks of International Business Machines.
Created using Turbo Pascal
Copyright 1983-92 by Borland International
When I first started writing this program my friends referred to it as
Marc's Menu. That's where the name MarxMenu came from. It has nothing to
do with either Carl or Groucho Marx.
TECHNICAL SUPPORT
Technical support for MarxMenu is provided in several ways. The first is
by calling our voice line 1-417-866-1222. We would ask that you not call
the 800 number as that is for orders and ordering information only.
We have several support staff and will try to answer your questions as
quickly and efficiently as possible. We at Computer Tyme look at
technical support as an opportunity to improve our product.
We also have a 24 hour 3 line BBS system. The BBS system is written in
MarxMenu script and the source code to the BBS is available for
download. Users with modems can leave messages about support issues.
There are several user uploaded menus here and it serves as a forum for
MarxMenu users to share ideas and techniques.
Our BBS number is 1-417-866-1665. It supports 14400 baud but is 2400
baud compatible. Use 8 bits, no parity, 1 stop bit (8N1). You will also
need to set your terminal emulation mode to ANSI or VT100. Do not try to
call the BBS with 7 bits or even parity. It won't work.
On our BBS are additional sample menu files that other MarxMenu users
like yourself have uploaded. We encourage you to share your work with
others so that more MarxMenu users can benefit.
Computer Tyme * MarxMenu * Users Manual Page #4
-----------------------------------------------------------------
When uploading problem menus to our BBS, try to isolate the problem and
send as small a sample as you can that demonstrates the problem. Be sure
to add a comment block in your code describing the problem and include
your name and phone number so that we can call you back when we are done
with your menu.
We are also available on Compuserve in the Novell vendors forum. From
any Compuserve prompt type GO COMPTYME. We have section 3.
We also have 3 fax servers on line. Our fax number is 417-866-0135. If
you're having a problem with menu code please don't fax long menus to
us. We prefer that you upload the code to our BBS so that we can run it.
We also offer a Fast Update Service which includes regular upgrades sent
to you automatically as we come out with them. This doesn't mean every
version of MarxMenu, but every few months after making several
improvements and the product is at a stable point. The Fast Update
Service includes special access to our support BBS.
This service is for the very fierce MarxMenu user who has to have the
"Latest and Greatest" all the time.
Computer Tyme provides technical support for users evaluating the
software as well as registered users. You should know your MarxMenu
version number before you call. If you type MARXMENU at the command line
it will give you a version number and a release date.
INSTALLATION
The following installation instructions are for both MarxMenu single
user version and MarxMenu network version. The network version is
included in The Network Survival Kit.
The single user version of MarxMenu is installed by copying the disks
into a subdirectory called MARX to keep the files better organized.
However, this is not necessary. Copy all the disks that come with
MarxMenu into a directory on your hard disk or network.
The Network Survival Kit is installed by copying the disk into a
directory on your server. Typically you would make a directory called
NSK under the PUBLIC directory. That way the NSK directory will inherit
the rights of PUBLIC. It will unpack into about 3.5 megs of programs and
documentation.
Once the files are copied into the proper directory, for example,
PUBLIC\NSK on the network or C:\MARX on a single hard drive, type
INSTALL. Be sure to have your serial number and access code ready. When
this is done, you can run some of the sample menus by typing MARX
<menu>.
Computer Tyme * MarxMenu * Users Manual Page #5
-----------------------------------------------------------------
Be sure to print out the DOC files on any programs you are interested in
and print out the MARXREAD.ME file. MARXHELP is activated by typing
MARXHELP at the command line.
IMPORTANT: Make sure you do not run the install from the floppy disk.
If you are running the Network Survival Kit on several file servers that
are bridged together, and you have purchased several single server
MarxMenus, be sure not to install the same serial number on more than
one file server. MarxMenu is smart enough to detect this. If you have a
multi-server version of MarxMenu, then you can install MarxMenu on
several fileservers without getting a license violation error.
On a Novell netowrk, MarxMenu stores it's serial number information in
the Bindery as well as the MARXMENU.EXE file. Thus when you get a new
version of MarxMenu it will serialize itself the first time you run it.
This makes updates easier.
-------- V E R Y * I M P O R T A N T --------
The MarxMenu subdirectory must be path accessible. That is, you must
have a path statement in your AUTOEXEC.BAT file that includes the
directory where the menu system resides. A typical path statement might
look like this:
PATH=C:\;C:\DOS;C:\MARX;
MarxMenu requires up to 100 bytes of free environment space. It won't
run without it. The way you get more environment space is to add a SHELL
command to your CONFIG.SYS file.
SHELL=COMMAND.COM /P /E:nnn
Where NNN is the number of bytes for the environment to reserve. Note
that if you are running DOS 3.1 then NNN is the number of 16 byte blocks
to allocate for the environment.
For DOS 3.2 or later:
SHELL=COMMAND.COM /P /E:400
For DOS 3.1:
SHELL=COMMAND.COM /P /E:25
If MarxMenu gives you an environment space error, this is where you go
to fix it. After changing the CONFIG.SYS file, you will have to reboot
the computer to make it take effect.
Another situation that can cause an "Out of Environment Space" error is
having more than one COMMAND.COM loaded. You can test for this by
running RAMMAP or MAPMEM. These programs will show you what's in memory.
If you need to load a second COMMAND.COM be sure to use the /E switch to
expand the environment of the new COMMAND.COM.
Computer Tyme * MarxMenu * Users Manual Page #6
-----------------------------------------------------------------
GETTING STARTED QUICK
After installing the software the first thing to do is try it out. Type
MARX QUICK (or MARX QUICKNOV for Novell networks) and a menu should come
up. Then select the Utilities option. This will open up another window.
You then choose DOS Menu and then Free Space. If everything goes right
the menu will run FREE.EXE and then return to the menu. After returning
to the menu press ESC a few times and exit back to the command line.
If everything works right then MarxMenu is working. If you get errors
then you'll need to fix them before going on. If you get an "Out of
environment space" error then you'll have to increase the environment
space before continuing.
The MarxMenu disk contains many sample menus for you to start with.
Which one to use depends on what your needs are. Typically on a single
user system you might start with QUICK menu.
To start with the QUICK menu, copy it to a different name such as MY.MNU
as follows:
COPY QUICK.MNU MY.MNU
Then edit MY.MNU with your favorite editor. You will quickly see how
this menu works and will be able to substitute your programs for the
ones it is set up for. You can then test and run your menu by typing
MARX MY.
If you want more of a self-configuring menu you might try the LEVEL1
menu. This menu requires no programming and lets you set up menus
interactively.
On a Novell network you might start with the QUICKNOV menu or translate
your existing Novell menus with NOVTRANS. The LOGIN menu requires a lot
of customization for your system. I wouldn't start on this menu until
your regular menus are written.
In the QUICK and QUICKNOV examples we have defined AddChoice and Task
procedures. These procedures are written in MarxMenu so you won't find
them in the list of MarxMenu's internal commands. AddChoice commands are
used with OnKey Task commands to create selections in the menu.
AddChoice('Directory Master',1)
AddChoice('Pick Directory',2)
AddChoice('Memory Map',3)
AddChoice('Free Space',4)
CornerStretchBox ('DOS Menu',38,15)
Computer Tyme * MarxMenu * Users Manual Page #7
-----------------------------------------------------------------
OnKey Task(1)
DM
OnKey Task(2)
PD
OnKey Task(3)
RamMap
Pause
OnKey Task(4)
Free
Pause
It's that simple! The AddChoice controls what you see on the screen and
the OnKey Task controls what it does. Under the OnKey command it's just
like writing a batch file.
The numbers in the AddChoice statements correspond to the OnKey Task(n)
statements so that Tasks are associated with choices. The
CornerStretchBox creates a self-sizing box where the upper left corner
position coordinates are specified.
You won't find the commands AddChoice, CornerStretchBox, or Task in the
manual. That's because they are procedures defined in Include files. The
QUICK and QUICKNOV menus include CUSTOM.INC and WINSUP.INC which allow
you to set up various features of the menus. CUSTOM.INC can include
either NOVELL.INC, BLOCK.INC, or GRID.INC which change the look and feel
of the menus. You might want to experiment with these to see which one
you like the best. You'll have to go into these three Include files if
you want to change the colors. PLEASE NOTE: If you revise an include
file, you will need to recompile your .MNU file with the MARXCOMP
compiler. Typing "MARX {menuname}" will not incorporate changes made
to any Include files until after you type "MARXCOMP {menuname}".
When you execute a menu after modifying include (INC) files, MarxMenu
doesn't automatically recompile the menu the same way it does when you
modify the menu file directly. After changing an Include file referenced
within a menu, you need to force a recompile by typing MARXCOMP QUICK or
you can delete the MRX file to force a recompile.
These menus are designed to get you going quickly. If you want to do
weird stuff MarxMenu can do weird stuff, but it takes a little more
work. The reason we have so many commands in MarxMenu is to be able to do
weird stuff so if you need to do something strange, we probably already
have a command to do it.
The example menus on disk (MNU files) show a variety of uses for
MarxMenu. They can be used like libraries of routines to cut code from
and paste into your current menu. A good way to learn MarxMenu is to
print out the example menus and study the code.
Computer Tyme * MarxMenu * Users Manual Page #8
-----------------------------------------------------------------
USE MARXHELP
MarxHelp is a TSR pop-up help program for MarxMenu. It acts as an online
reference guide to all of the MarxMenu commands. MarxHelp only takes 8k
of RAM and is very useful while writing your MarxMenu menus. It gives
you the complete manual on-line and is fully indexed electronically. It
even has a keyword search to help you find the command you are looking
for.
I strongly encourage the use of MarxHelp. MarxHelp has everything this
manual has in it and more and it is easier to read and find things than
thumbing through pages. MarxHelp is updated with every release of
MarxMenu and contains new features and program changes the paper manual
doesn't. Once you get used to using it, you won't want to go back to
paper documentation. Using MarxHelp is better than using the manual.
To load MarxHelp type MarxHelp at the command line. This prepares
MarxHelp to be available as a TSR while you're creating or editing a
menu file. Then if you want to pop up an index press Shift-F3. The
Shift-F2 key will repeat your last help topic and Shift-F1 will look up
the word your cursor is on.
To get more help on MarxMenu type MarxHelp /?. If you need to unload
MarxHelp from memory, type MarxHelp /U. Once you bring up MarxHelp, read
the Help on Help section for more detailed information on how to use
MarxHelp. MarxHelp also contains the entire text of the DOS ToolBox and
Network Survival Kit utilities.
MarxHelp comes with the Computer Tyme Network Survival Kit. It can also
be downloaded from our support BBS. It does not come bundled with the
single user version.
COMMON QUESTIONS AND MISTAKES
There are some common mistakes people make that I get a lot of calls
about. I'm going to attempt to point these out so that you don't waste a
long distance call over something that's in the book.
When running MarxMenu as a menu you type MARX menuname and not MARXMENU
menuname. You must run the MARX.BAT file in order for MarxMenu to be
able to execute other programs.
MarxMenu MUST be in your search path. When you type PATH at the command
line, make sure that the MarxMenu directory is in the path. If it isn't,
put it in because MarxMenu will not work unless it is added to the path.
If your menu is stuck in a loop and you can't get out, it is because
MarxMenu is not in the path.
Computer Tyme * MarxMenu * Users Manual Page #9
-----------------------------------------------------------------
When running MarxMenu on a network, MarxMenu will want to create it's
temporary batch files in the same directory where MarxMenu is located.
The user must have enough rights to create these files. If you don't
want to give the user rights in this directory then set an environment
variable TEMP to point to a directory where the user does have rights.
If you notice that you (as supervisor) can run the menu just fine, but
your users get errors, it's because they don't have enough rights.
When using MarxMenu to logon to or logoff from the network, you need
to follow all the rules in the sections on network usage. It is very
tricky to do these functions and there are things you can do and things
you can't. There are things that you think should work but don't. So, I
strongly suggest that you follow the instructions. I have spent hundreds
of hours fighting these issues and I have pretty much figured out what
you can do and what you can't do.
If you are getting "Bad Command or Filename" errors when running
MarxMenu, edit the first line of MARX.BAT and turn ECHO ON. Then you can
watch what is happening. You can also put PAUSE in so it won't go by too
fast that you can't see it.
Another common question is, "Do you have a command that does this?" The
quickest way to hunt up commands is to use the MarxHelp TSR. Besides
being highly cross-indexed, it also has word search capabilities.
Several of the example files have Include files. I use the INC extension
on these files. Commands like AddChoice and CornerStretchBox are
procedures that are defined in these Include files and are not MarxMenu
commands. This is also where the menu colors are defined.
When using the Novell menu translator you may get a "Window Out Of
Bounds" error. This means that the Novell menu has more choices than
will fit on the screen. The solution is to break up the menu into
submenus.
Also, when running the translator you type MARXMENU NOVTRANS menu, not
MARX NOVTRANS menu. Since the menu translator is being used as a
translator instead of a menu you use MARXMENU instead of MARX.
When upgrading MarxMenu from a previous version, you must chase everyone
out of the menu before upgrading. Otherwise the MARXMENU.OVR file is
locked and can't be overwritten. I suggest deleting the old MARXMENU.OVR
file first. If you can delete it then everyone is out. I get calls about
this where the supervisor swears everyone is out of the menu when they
aren't. If you can't delete the file then someone has it open.
When you upgrade MarxMenu the MRX files need to be recompiled. If the
MNU files are available and the users have enough rights then this
happens automatically. But, if the users don't have enough rights they
won't be able to run the menus. You will have to go in and recompile
them. IMPORTANT! Do not lose the MNU files. The MRX files cannot
be uncompiled and if you don't have the MNU files, you have no
way to alter your menus.
Computer Tyme * MarxMenu * Users Manual Page #10
-----------------------------------------------------------------
You must have some free environment space for MarxMenu to use. If you
get an "Out of Environment Space" error, it means that you are out of
environment space. First check to see that you have SHELL= command in
your CONFIG.SYS file. Then use RAMMAP to see it you are loading more
than one COMMAND.COM. You can also use the FREE.EXE program to show you
how much environment space you have. If FREE doesn't show that you have
very much free space then you are going to have to figure out why.
When Novell installs their utilities they flag files as "Sharable
Read-Only". Don't do this with MarxMenu. This is a bad idea and is a
left over from DOS 2.11. Even though Novell still does it, don't you do
it. It can, and often does, cause problems.
Not all programs are compatible. Sometimes you never know why. The
solution often is to find a work around. MarxMenu supports many kinds of
work around tricks. Sometimes the trick is to exit the menu with the
keyboard buffer stuffed to run a program from the command line.
Because of the power and flexibility of MarxMenu, many new users try to
do complex things too fast. I recommend that you start with the basic
menu examples and get familiar with the software. Once you are familiar
with MarxMenu you aren't as likely to get in over your head with it's
more complex features.
Q.) This is a big manual. Will it be hard to learn?
A.) No. MarxMenu is one of the easiest menus to learn and install. You
don't have to learn hundreds of commands to make it work. Just start
with the sample menus. But, if you want to do complicated tasks, the
commands are there. But the more complicated the task the more effort it
will take to make it work.
Q.) I type MARXMENU QUICK and when I try to run something it dumps me
back at the command line.
A.) To run a menu you need to run the MarxMenu from MARX.BAT. You should
type MARX QUICK instead of MARXMENU QUICK.
Q.) I'm getting "Error accessing Overlays!"
A.) MarxMenu requires the file MARXMENU.OVR file to be in the same
directory as the MARXMENU.EXE file. In previous versions of MarxMenu the
EXE and OVR files were combined. This causes file sharing problems on
some networks and dumb multitaskers such as Windows. So we had to
separate the overlay file.
Q.) Everything was working fine and then I moved the files to another
directory and now I'm getting "Bad command or File Name".
Computer Tyme * MarxMenu * Users Manual Page #11
-----------------------------------------------------------------
A.) The MARX.BAT is generated for a specific directory. Use your editor
or MARXEDIT to edit MARX.BAT to run in the new directory. If you
are still having problems change the ECHO OFF to ECHO ON and
watch the batch file execute. You can type MARXMENU INST to
recreate the batch files.
Q.) I get stuck in the menu and it won't exit. Just keeps looping.
A.) The MXSTOP.BAT, BATEXIT.BAT and DROPTO.BAT files need to be in the
same directory as MARX.BAT and MarxMenu. MarxMenu must be on your search
path in order to work.
Q.) I'm running LanTastic and when two people use the menu at the same
time I get a "File Sharing Violation" error.
A.) This is solved by setting the MARXMENU.OVR file to "Read Only".
Q.) I tried changing the menu colors by editing the NOVELL.INC file but
no colors changed. What am I doing wrong?
A.) MarxMenu automatically recompiles when you change the menu file
because it compares the date of the MNU file to the MRX file. Include
files are not compared this way. What you need to do after changing an
Include file is to force MarxMenu to recompile. This is done by typing
MARXCOMP <menu> or by deleting the MRX file.
Q.) When I run some programs, (MultiMate) and come back to the menu my
colors are gone. It comes up in black and white.
A.) Some programs change the video mode to BW80 and leave it that way.
MarxMenu comes up black and white when this happens. Add the command
MODE CO80 after the offending program and your colors will come back.
Q.) Under an OnKey statement, I'm mixing batch file commands and
MarxMenu commands (using the "|" (vertical bar)). It seems that all the
MarxMenu commands execute first rather than in the order that I
specified.
A.) Yes, since MarxMenu is a zero "k" menu system, all batch files
commands are written to a batch file and executed when MarxMenu exits.
It is also important to remember that when you return to MarxMenu that
you come back to the beginning of the menu and not the last line you
left.
Q.) On my Novell network, I get "Error creating BAT file" when users try
to run programs from the menu.
A.) This is caused when users don't have enough access rights for
MarxMenu to create temporary batch files. Use the SET TEMP=directory
to point to a directory where the user has full access rights.
Computer Tyme * MarxMenu * Users Manual Page #12
-----------------------------------------------------------------
Q.) I'm trying to execute a program and read the DOS errorlevel code and
it isn't working. What am I doing wrong?
A.) To read a DOS errorlevel code into a ReturnCode you must use the
MarxMenu Execute command. You must also set UseCommand to Off and you
need to specify the COM or EXE extension. You also can't use the DOS
piping or redirection commands.
Q.) Can I run Windows with MarxMenu?
A.) Yes, MarxMenu works just fine with Windows. It can start Windows and
when you exit Windows it comes back to MarxMenu.
Q.) When I try to log off a Novell network from the menu I get a
"Missing Batch File" error.
A.) The reason you get a "Missing Batch File" error is because MARX.BAT
is on the network and is no longer accessible after LOGOUT runs. Under
MarxMenu the correct way to log off is to create an OFF.BAT file in the
SYS:LOGIN directory and run |Logoff under an OnKey command. MarxMenu
will automatically find this batch file and run it.
Example:
OnKey 'L'
|LogOff
Q.) When I call your BBS I get a lot of arrow characters on my screen.
What am I doing wrong?
A.) My BBS uses ANSI sequences. Turn on your ANSI or VT100 emulation in
your terminal program and it will work just fine.
MARXMENU FEATURES
The basic idea behind MarxMenu is to display choices to the user, let
him select a command, run the program without taking any memory, and
return to the menu when done.
The way MarxMenu works is that you start it with a batch file which runs
MarxMenu. When the user selects an option MarxMenu writes a batch file
and quits. The first batch file (MARX.BAT) calls the batch file that
MarxMenu created which runs your application. When your application
finishes the MARX.BAT file reloads MarxMenu and waits for the user to
make a new choice.
MarxMenu uses a script language that is designed around being simple to
use and to read. The script language is used to paint the screen, wait
for the user to input a key, and then write a batch file based on that
key. To help you get going, MarxMenu comes with several prewritten
sample menus that you can use as templates to make your menus. These
templates are somewhat feature rich so that you don't have to figure out
very much to get your MarxMenu going. The sample menus are designed to
meet the needs of most menu users and are designed to get you up and
running quick with as little pain as possible.
Computer Tyme * MarxMenu * Users Manual Page #13
-----------------------------------------------------------------
But, MarxMenu is feature rich and has plenty of commands for those of
you who want to do something weird. With over 850 commands and growing
we have attempted to deal with many problems that users and network
supervisors need to solve. So if you want to do something that my menu
templates aren't set up to do then you have the power to get in and make
MarxMenu do what you want. But it takes a little more effort to make it
happen.
The stranger you want to get with MarxMenu the more learning and effort
it will take. But, unlike all the other menu systems out there, MarxMenu
will get as strange as you need it to get. MarxMenu is a programming
language targeted at non-programmers and puts the power of a
professional programmer into the hands of those who have never written a
line of code before. Even though MarxMenu may not be a true compiler or
have the execution speed of C or Pascal, MarxMenu supports a far richer
command language and a more elaborate method of automatic memory
management. With MarxMenu you can write programs that would normally
require 30 points higher IQ and used to be limited to the realm of the
serious computer nerd - like me!
OVERVIEW OF THE MARXMENU SYSTEM
MarxMenu is not just another fill-in-the-blank menu system. It is a menu
programming language and job control language. It gives you total
freedom to do whatever you want, but total freedom has a price. You will
need to know and understand how to use a text editor. This isn't
difficult if you are familiar with using a word processor. And you will
need to have a basic understanding of DOS and how batch files work.
With a text editor you can create a menu file which is a text file with
an MNU extension. Or, you can copy and then modify the text file
QUICK.MNU which displays the menus you see when MarxMenu is executed.
This text file contains a set of instructions for MarxMenu to follow.
MarxMenu will then read your menu file and run the instructions.
A menu file might look as follows:
DrawBox 31 5 18 4
UseArrows
Writeln ' W - WordStar'
Write ' L - Lotus'
OnKey 'W'
CD\WORDSTAR
WS
OnKey 'L'
CD\LOTUS
LOTUS
Computer Tyme * MarxMenu * Users Manual Page #14
-----------------------------------------------------------------
The above example is a fully working MarxMenu program. Just because
MarxMenu has over 850 commands doesn't mean you have to use them all.
The reason there are so many commands is that people keep calling and
asking if we can add such and such. Most of the time we do. That's why
the manual gets behind sometimes.
The instructions must be from the vocabulary of words that MarxMenu
understands. These words make up the command list included in this
manual. They must be used precisely as the instructions in this manual
tell you to use them. This process is called programming.
I know that for many of you the word programming is a scary word. Put
your fears at ease, MarxMenu is one of the easiest programming languages
there is. It is a little harder than writing batch files and a lot
easier than Basic. It requires a working knowledge of DOS and an
understanding of writing batch files as explained in your DOS manual.
The point that we want to make is, do not let the fear of learning and
the fear of programming prevent you from learning to write your own
menus. If you have never touched a computer before and are sitting down
with your first PC, read the manuals first. Become familiar with the
MS-DOS operating system. Learn how to write batch files, make
subdirectories, copy files, format floppies, etc. If you don't
understand something, ask a friend. All of us had to learn sometime, and
there is no such thing as a stupid question.
After you have mastered some of the basic concepts of the operating
system, then learn MarxEdit. This is the text editor included with your
MarxMenu program. Use it to write your own batch files. Then attempt to
write your own menus by modifying the sample menus (files with a MNU
extension) which come with MarxMenu. Print these menus and study them,
referring to this manual or MarxHelp for help on command definitions.
You do not have to completely understand them to start making changes.
Programming is a trial and error process.
A computer, like a musical instrument, is only as good as the player.
The more you learn about it the more you'll find it can do. In fact, a
computer can help raise your effective IQ as you learn the disciplines
of logic and reason. As a hammer is a tool of the hand, enhancing your
physical strength, a computer is a tool of the mind, enhancing your
mental strength. You will learn that as you develop a relationship with
your computer, that you will be able to process information in ways you
never dreamed.
MarxMenu is an excellent learning tool. By the time you become
proficient with the menu language, you will have learned the fundamental
concepts behind the MS-DOS operating system. You will find yourself
going back and forth between this manual and the DOS manual that came
with your computer. When you master the language, you will have enough
computing skills to be a real resource in your office environment. In
this day and age, knowing how to "make the damn things work" is a key in
moving up the corporate ladder.
Computer Tyme * MarxMenu * Users Manual Page #15
-----------------------------------------------------------------
If you have sufficient excess income to afford a personal computer, or
are in a job that provides you with a workstation, you are smart enough
to learn this program. All it requires is that you take the time. You
can do it. It is worth your time, and you will make up the time spent in
the results you'll get. Good luck and enjoy.
WHAT MARXMENU DOES
So with hundreds of menus on the market, what makes this one so great.
Well, let me tell you about it. MarxMenu is a menu language rather than
a fill in the blank kind of menu. MarxMenu gives you total control of
your computer system.
It is also a job control language allowing you to program processes too
difficult to do with batch files. MarxMenu can be used to do anything
from overnight batch job processing to generating control scripts for
mainframes.
Because of it's simple syntax, MarxMenu makes an excellent teaching
language putting more programming power in the hands of the student
programmer than any other programming language.
As a menu, MarxMenu can be as simple or as complex as you want. If you
want simple, nothing is easier. If you want POWER, nothing is more
powerful. If you want to get really weird, MarxMenu can do really weird.
So if you want the menu to remind you to go vote, MarxMenu knows when
the first Tuesday after the first Monday in November on even years is.
If you are into Astrology, and you want certain menu items to appear
only if Mars is in the right place in the sky, MarxMenu can calculate
the orbit of Mars for you.
MarxMenu can be used to program games, write running software demos and
online tutorial programs. It can be used to write testing programs. It
can be used to write custom software installation programs. It can be
used to assist other applications to make other software more network
friendly.
MarxMenu has a compiler for high speed execution. Even very large menus
come up in under 4 seconds on a 4.77mhz IBM XT on an ArcNet lan. The
compiler also provides security in that you can keep your source files
separate so no one can alter the menu files.
Computer Tyme * MarxMenu * Users Manual Page #16
-----------------------------------------------------------------
THE MARX.BAT FILE
In order for MarxMenu to work, a MARX.BAT file must be created. This is
done by typing INSTALL. The first thing that INSTALL does is unpack the
compressed menu files and documentation files. Then it will bring up the
installation menu.
The MARX.BAT file looks like this:
@ECHO OFF
C:\MARX\MARXMENU.EXE %1
%MXCMD%
MARX %1
The first line of MARX.BAT turns the echo off. This may be changed to
ECHO ON for debugging purposes. PAUSE commands can be inserted to debug
a menu. This allows you to see what's going on.
The second line of MARX.BAT runs MARXMENU.EXE. The second parameter %1
is the name of the menu file to run. A third parameter can be added to
tell MarxMenu to use a specific directory for creating temporary batch
files. Otherwise MarxMenu will create temporary batch files in the same
directory as MARXMENU.EXE.
When the user selects a program to run, MarxMenu writes a temporary
batch file which contains within it the commands to run the program.
Then MarxMenu writes a command to the environment variable MXCMD to
execute the temporary batch file and exits.
What it writes depends on the version of DOS you are running. If you are
running DOS 3.3 or later, MXCMD is set to CALL <batch>. If you are
running an earlier version of DOS then MXCMD is set to COMMAND /C
<batch>.
Whatever command is written to MXCMD is executed in line 3. This usually
calls the temporary batch file that MarxMenu created. This executes your
program and returns to MARX.BAT.
Line four jumps back to the beginning of the batch file and starts all
over. %0 is MARX.BAT and %1 is the name of the menu you are running.
MARX.BAT
-------- +--MarxMenu Creates--+
+----> @ECHO OFF | |
| MARXMENU.EXE %1 |
| %MXCMD% >--+ +-> $MX00000.BAT
| +--> MARX %1 + | ------------
| | | +----------------------> CD\WORDSTAR
+-|------<-----+ WS --+
| |
+-------------------------------------------<-+
Computer Tyme * MarxMenu * Users Manual Page #17
-----------------------------------------------------------------
Note: MarxMenu sets MXCMD = CALL $MX00000.BAT
You can also tell MarxMenu where to put it's temporary batch files by
setting an environment variable TEMP to point to a temporary file
directory.
Example:
SET TEMP=F:\TMPFILES
This is compatible with the way DOS 5 and Windows uses temp files.
When you exit the menu system. MarxMenu sets MXCMD to MXSTOP. This jumps
to a batch file called MXSTOP which gets you out of MARX.BAT. MXSTOP.BAT
can be modified to control what happens when MarxMenu is exited.
The default MXSTOP.BAT file is as follows.
SET MXCMD=
SET KSV=
REM You can control menu exiting with this file!
Note that by adding your own commands to MXSTOP that you can control
what happens when you exit. You could loop right back to the menu if you
want. Or, you could force a controlled network logoff.
I strongly recommend upgrading to DOS 3.3 or later whenever it is
possible to do so.
The name of the temporary batch file is as follows:
$MX00000.BAT
||||
Shells--------+|++--------Network Station (Hex)
Task Number
The five zeros are used for single user versions of MarxMenu. On a network
they change as follows:
The last two zeros is the station number on the network. This is either
read directly from the shell, if you are using Novell, or from the
environment variable STATION if you are on another network. The third
zero is the task number if you are running DesqView, or from an
environment variable TASK if you are running some other multitasker.
The second zero is replaced by one less than the number of COMMAND.COM
shells you are running. This way if you run COMMAND.COM under MarxMenu
and then run MarxMenu again under that, it doesn't get lost when you
exit.
Computer Tyme * MarxMenu * Users Manual Page #18
-----------------------------------------------------------------
The first zero is for future expansion. In case something comes along
that we haven't thought of.
If you want to do custom tricks, MarxMenu has an internal variable
called MxCmd. Setting this to your own command overrides the way
MarxMenu would normally use it.
But now you ask, does MarxMenu leave a trail of batch files that will
clutter up my drive or network? Not at all. MarxMenu keeps using the
same names over and over again. If a user crashed his system, it might
leave a batch file but it would be overwritten the next time he used the
menu. Not only that, all batch files can be kept in the same directory
so cleaning up is as simple as typing DEL $MX*.BAT!
By writing to the MXCMD variable you can run an EXE or COM file directly
without having to create another batch file.
Example:
OnKey 'M'
|MxCmd = 'RAMMAP'
This runs RamMap directly from the MARX.BAT file.
Another trick is to run another batch file without the CALL statement.
This creates a one-way jump to another batch file.
Another debugging feature. You can change the first line of the MARX.BAT
file as follows:
@ECHO %MXECHO%
This allows you to turn the echo on for debugging purposes by typing:
SET MXECHO=ON
This way you don't have to change the MARX.BAT file to debug. If you use
this, make sure that MXECHO is set to either ON or OFF.
DROPTO.BAT
If you are going to run a shell like COMMAND.COM under MarxMenu it is
sometimes better to use DROPTO.BAT which is created during the install
process. DropTo allows you to jump from the temporary batch file that
MarxMenu creates to DropTo, which deletes the temporary batch file and
executes the rest of the command line.
Usage: DROPTO %0 COMMAND.COM
Computer Tyme * MarxMenu * Users Manual Page #19
-----------------------------------------------------------------
If you are using DropTo inside a MarxMenu, the %0 is automatically added
for you.
Example:
OnKey 'C'
DropTo COMMAND.COM
DROPTO.BAT
----------
DEL %1
SET KSV=
SET MXCMD=
%2 %3 %4 %5 %6 %7 %8 %9
Here's how it works:
$MX00000.BAT <------deletes this file--------+
------------ |
DROPTO %0 COMMAND.COM ------------> DEL %1 >-+
SET KSV=
SET MXCMD=
%2 executes COMMAND.COM--> %2 %3 %4 %5 %6 %7 %8 %9
The advantages are that the temporary batch file is eliminated so if the
user never returns to the menu, it leaves no temporary file to clutter
up the drive. Also, DROPTO.BAT becomes the pending batch file that is
running rather than the temporary file.
SUPPORT FOR EARLY DOS VERSIONS
There are two main differences between DOS versions earlier than 3.3 and
versions 3.3 and above. One is the CALL command for batch files and the
other is the way you specify environment space when using COMMAND.COM.
I have enhanced the support for early DOS versions (3.1, 3.2). MarxMenu
executes COMMAND /C /E:nn (batchfile) >NUL to have one batch file call
another. The first two lines of the batch files created are as follows:
ECHO OFF
CTTY CON
....
This eliminates the ECHO OFF from being seen.
Also whenever possible, when MarxMenu loads a copy of COMMAND.COM, it
adds the /E:nnn command to set the environment space to the same as that
of the Master Environment. In version 3.1 it is translated to paragraphs
instead of bytes.
Computer Tyme * MarxMenu * Users Manual Page #20
-----------------------------------------------------------------
One thing to note in early versions of DOS. If you run a batch file
under COMMAND /C and your batch file has SET commands to set environment
variables, the changes you make will disappear as soon as you get back
to MARX.BAT. Why? Because you loaded another COMMAND.COM and the SET
commands set its environment. When this COMMAND.COM ends, it takes its
environment with it. Under DOS 3.3 or later, which uses CALL instead of
another shell, the SET commands live. (Yet another reason to upgrade).
ABOUT ENVIRONMENT VARIABLES
I've been talking a lot about environment variables. Some of you out
there in novice land don't know what an environment variable is. Many
others don't know the intricate secrets handed down from the Great DOS
Masters who know all the intricate undocumented features of DOS.
Your DOS shell, COMMAND.COM owns an area of memory called the Master
Environment. It contains strings in the form Name=Value. Included among
those strings are your COMSPEC and your PATH. Your COMSPEC tells DOS and
other programs where to find COMMAND.COM. Your PATH tells DOS and other
programs what directories to search when loading programs. Another
common environment variable is your PROMPT. This controls what your DOS
prompt will look like.
Environment variables are commonly set using the SET command. This is
done by typing SET NAME=VALUE.
Example:
SET COLOR=BLUE
So what does this actually do? Nothing, unless you have a program that
reads the environment variables that is looking for one called COLOR.
This way, environment variables can be used to leave messages to other
programs and control how they behave.
Besides leaving messages, environment variables can be accessed by batch
files. If you use %NAME% in a batch file, DOS will substitute the VALUE
of the variable for the %NAME% expression. And this feature is important
to MarxMenu's operation.
MarxMenu uses an environment variable called MXCMD. In the MARX.BAT file
the third line is %MXCMD%. So MarxMenu controls MARX.BAT by writing
values to MXCMD.
In order to do this, there must be enough room in the environment for
the command to fit. That is why you need to make sure that you have a
SHELL command in your CONFIG.SYS to set space for MarxMenu to use.
Now so far I've only talked about the Master Environment. That's the one
that the first COMMAND.COM owns. Each program that is loaded, including
TSR's, gets a copy of the Master Environment in its own environment. This
is called the CURRENT Environment.
Computer Tyme * MarxMenu * Users Manual Page #21
-----------------------------------------------------------------
One interesting feature of the Current Environment is that it is smaller
than the Master Environment. DOS only creates enough space to hold a
copy of the space used in the Master Environment and a little more to
store the name of the program that is running.
If one program executes another program, the environment of the parent
program is called the Parent Environment. You will probably never need
to deal with the Parent Environment but MarxMenu can access it in case
you do.
Another environment is the SHELL ENVIRONMENT. This is the one that THEY
never talk about. The one you'll never read about in any books. The one
you'll never learn about in any DOS classes. This is the one your
parents never mentioned.
The Shell Environment is normally the same as the Master Environment.
But, if you are running more than one level of COMMAND.COM, the Shell
Environment is the environment of the last COMMAND.COM in memory. This
environment is the most important environment to MarxMenu.
So why load up two or more COMMAND.COM's? There are several cases where
this could occur. One case is when you want to run COMMAND.COM as a
program under MarxMenu. This way you can type EXIT to get back to the
menu. If you do this and then run MarxMenu again, you have two levels of
COMMAND.COM. In this case, the first COMMAND.COM is the Master
Environment and the second COMMAND.COM is the Shell Environment.
Another place where more than one COMMAND.COM is used is if you are
running Microsoft Windows 3 or DesqView. Both of these programs are able
to run a DOS shell. When you do, this is a second level of COMMAND.COM.
What is important is that SET commands and %NAME% commands in batch
files deal only with the Shell Environment and not the Master
Environment.
MarxMenu can treat environment variables as if they were MarxMenu
variables. By writing to environment variables you can store information
that stays there even if you leave MarxMenu and return.
Example:
Writeln %PATH%
%PATH% = 'C:\;C:\DOS;'
Computer Tyme * MarxMenu * Users Manual Page #22
-----------------------------------------------------------------
DEALING WITH MULTIPLE DOS SHELLS
If you are running more than one level of COMMAND.COM (shelling from
Windows, DesqView, Word Perfect Office) and having environment space
problems here's a trick. Before you load up your fancy shells, put this
in a batch file like your AUTOEXEC.BAT.
SET MXCMD=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
This variable will be trashed by MarxMenu thus freeing up the
environment space it occupied. This will not only allow MarxMenu to run
but may solve problems with other programs you are running that need
environment space as well.
Another option is, if you can control how the second shell is run, add
the /E switch to the command line of COMMAND.COM to force a larger
default environment space.
Example:
COMMAND.COM /E:400
MARXMENU AND TSR CONTROL
MarxMenu along with the TSR utilities that come with MarxMenu, can load
and unload TSR's under menu control. This is handy when you want to run
a big application and need to free up some memory to do it. Since
MarxMenu is a zero k menu system, unloading TSR's is possible but it
has it's tricks.
The problem you run into is that when one batch file calls another batch
file, the way MarxMenu normally runs, DOS creates a small batch file
control block in memory. This control block stays in memory after the
TSR is released creating a region of trapped memory. Although this
memory is freed, it isn't usable.
The way around it is to jump to the batch file that releases memory
instead of calling it. This is done by setting MXCMD to the name of the
batch file you want to run. The only problem is that when you jump to
the other batch file, it won't automatically return to MARX.BAT. You
must therefore end your batch file with a command bringing you back to
MARX.BAT.
MEMHOG.BAT
-----------
Rem UnLoad SideKick
RELEASE SK
CD\MEMHOG
MEMHOG
MARK SK
SK
MARX MAIN
Computer Tyme * MarxMenu * Users Manual Page #23
-----------------------------------------------------------------
In your MAIN menu:
OnKey 'H'
|MxCmd = MEMHOG
See the documentation file on the TSR utilities disk for more
information on how to use MARK and RELEASE.
NETWORK USERS:
The main thing you have to worry about on a network is to make sure that
when MarxMenu creates a temporary batch file, that it is a different one
for each user on the network.
This is handled several ways. If you are on a Novell network, MarxMenu
uses your station number as part of the name for the temporary batch
file. If you are not using Novell, then you will need to set an
environment variable STATION for each workstation on your net. Each one
has to be a different number.
Example:
SET STATION=5
You must ensure that the user has enough access rights to create
temporary batch files in the directory selected for temporary batch
files. One solution is to create a batch file directory and give all the
users full access rights to it.
MarxMenu has been run on about every DOS based network that exists. If
the network runs at all it will generally run MarxMenu. Among the
networks that come to mind are Novell, Lantastic, Banyan, 3COM, Lan
Manager, IBM, DECNET, ConCurrent DOS, PCMOS, and SCO VPIX. MarxMenu is
running on networks as small as two users to as large as 20,000 users.
In fact, the bigger your network, the more you need MarxMenu.
If you are running Lantastic and get a "sharing violation" error when
two people try running the menu at the same time, try setting
MARXMENU.OVR to READ ONLY.
NETWORK MENU STRATEGY
One of the main features of MarxMenu is the ability to create "smart"
menus. This allows you to have a single menu that everybody runs but
each user sees different selections based on what their access rights
are, what groups they are in, what kind of hardware is available, or
what workstation they are on.
The group access feature is a very good example of using the power of
MarxMenu. The idea here is that for instance under Novell you would put
users in groups and have menu selections appear based on group
membership. Thus only the accounting department sees the payroll
selection.
Computer Tyme * MarxMenu * Users Manual Page #24
-----------------------------------------------------------------
On non-Novell networks you can group users by having them in a text file
list of members. Then you can read the list and test if they are in the
list. You can also read environment variables and control choices based
upon the result.
The rule with networks is to keep things as consistent and simple as
possible. A simple well-documented network is a happy network, and it
can make the difference whether you go home on the weekends or stay at
the office.
USING TRUENAME ON NETWORKS
Besides using drive letters, networks use a file and directory naming
convention called TrueName. The MarxMenu TrueName function returns the
true name of a file. TrueName files are specified as follows:
Microsoft Networks:
\\SERVER\DIRECTORY\FILE
Novell Netware:
\\SERVER\VOLUME\DIRECTORY\FILE
By using TrueNames you can specify files and directories on the network
without having to map drive letters or make redirection list entries. If
a TrueName of a string ends in a '\' then it is at the root directory.
Example:
C:\ ;root of C
\\TYME\SYS\ ;root of server
\\TYME\SYS\PUBLIC ;not root directory
NOVELL USERS:
Novell is the most popular network on the market. We have added many
enhancements for Novell networks to support things like logging in and
logging out, drive mapping, group support, software metering, and status
information.
Although Novell is a high quality solid product it has its own
"personality" and many undocumented features otherwise known as bugs.
Most people who are having trouble with MarxMenu under Novell are really
having trouble with Novell. Quite frankly, we do more Novell support
than we do MarxMenu support.
Having said that, we have two Novell networks. One at the lab and one at
home and we love networks. But, we have spent hundreds of hours learning
all the tricks. And to save you a phone call, and a lot of time, we've
decided to share these tricks here in the manual.
Computer Tyme * MarxMenu * Users Manual Page #25
-----------------------------------------------------------------
Some of these tricks are from the Great Network Gurus themselves who are
so advanced that they no longer exist in physical form. These people
live in another dimension of total mental existence and can only be
reached by modem. Some of them hang out on Compuserve.
We therefore strongly recommend that if you are a serious Novell user
that you join Compuserve and hang out in the Novell section. And just
because not everyone on Compuserve is a real person doesn't mean that
you should feel uncomfortable asking them any question about your
network that you need to ask.
THE NOVELL MENU TRANSLATOR
One nice bonus with Novell networks is that MarxMenu can translate your
Novell menus to MarxMenu. This saves you the time of having to recode
your system. What you do is type:
MARXMENU NOVTRANS <menu> <- Right Way
MARX NOVTRANS <menu> <- Wrong Way
This translates your Novell MNU file to a MarxMenu file. Your MNU file
is renamed with an NOV extension.
Once the menu is translated you run it by typing MARX <menu> instead of
MENU <menu>. MarxMenu can run Novell's menu better than Novell runs
their own.
Sometimes the translator isn't perfect and it takes a little tweaking of
the original menu file for the translator to work properly. If you have
problems translating a menu and can't make it fly, upload a copy to our
BBS system and let us take a look at it. You might discover something
that we should use to enhance the translator menu itself.
One problem some users experience is translating Novell menus with
greater than 20 menu options. The Novell menus scroll when there are
more options than can be displayed on a single screen. NovTrans
translated menus do not support this. When we get calls on this issue,
we recommend users to break up their menus into logical groupings,
putting applications in one window, utilities in another, etc. If you
should experience this problem, use logical groupings to work around it.
If you get a "Window Out Of Bounds" error it is probably because you
have more choices than will fit on the screen.
After you are satisfied with the translation you can then start
enhancing your menus by editing the new translated menus. You might want
to run QUICKNOV and look at it's features. If you like what you see you
can use your editor to cut and paste code from QUICKNOV.MNU into your
menus.
Computer Tyme * MarxMenu * Users Manual Page #26
-----------------------------------------------------------------
You can also start adding InGroup commands to create conditional menus.
Under MarxMenu you can have one single smart menu for everybody instead
of a lot of individual menus.
Example:
if InGroup('ACCOUNTING')
AddChoice('Payroll',10)
endif
The translated menu is set up with a lot of features that you can add
that the original Novell menu wouldn't do. These features include
software metering and usage logging (See METER.INC for details). You can
also control screen blanking and add password security for unblanking
the screen. MarxMenu can be set up to log you off the network after a
period of inactivity (See CUSTOM.INC for details).
The translated menu also allows you to select various look and feel
options by selecting NOVELL.INC, BLOCK.INC or GRID.INC. These three
files are similar and you can edit them to change the colors of your
menu interface.
One thing to remember is that when you change an Include file you need
to force MarxMenu to recompile the menu. It doesn't automatically
recompile like it does when you change the .MNU file. To force MarxMenu
to recompile you just type MARXCOMP <menu> or delete the MRX file. (The
MRX file is the compiled file that MarxMenu uses to actually run your
menus.)
LOGGING OUT UNDER MENU CONTROL
Logging out under menu control is one of the trickiest things to do. The
problem is that as soon as LOGOUT executes, you no longer have access to
the network. This means that if you are in a batch file, you are going
to get a "Missing Batch File" error, unless the batch file is in the
\LOGIN directory.
Another problem with logging out is making sure that your COMSPEC is
pointing to a COMMAND.COM that is either on the local drive or in the
\LOGIN directory. Otherwise you will get a "Cannot load COMMAND.COM"
error.
Another problem that you need to deal with is that your PATH command
needs to be changed so that it doesn't refer to mapped drives that are
no longer accessible.
If you are logging off with a batch file, the batch file must be in the
login directory or a local drive. If it is in the login directory your
current drive must be the first network drive (usually F:) and this
drive must not be map rooted to any directory.
Computer Tyme * MarxMenu * Users Manual Page #27
-----------------------------------------------------------------
What you need to do is create a batch file in the \LOGIN directory
called OFF.BAT.
Example:
F:\LOGIN\OFF.BAT
SET COMSPEC=C:\COMMAND.COM
LOGOUT
C:
PATH=C:\DOS
To run this file the current directory must be F:\LOGIN. When using the
MarxMenu command Logoff, MarxMenu changes to the \LOGIN directory of the
first network drive, removes any map roots on this drive, and runs
OFF.BAT.
Setting up an OFF.BAT file is compatible with MarxMenu's automatic
network logoff feature. This is where you can set the amount of time to
wait at a menu before it automatically logs you off the network.
Another way to logout under MarxMenu is to stuff the LOGOUT command into
the keyboard buffer and exit MarxMenu.
Example:
OnKey ESC
|StuffKBD 'LOGOUT' + CR
|ExitMenu
Another logout trick is to use the LOGOFF utility from the Computer Tyme
Network Survival Kit. This program automatically fixes your PATH and
COMSPEC after the logoff occurs.
LOGGING IN WITH MARXMENU
If there is any one thing that's trickier than logging out of a Novell
network, its logging in. We have spent MANY hours struggling with Novell
trying to get it right and have finally figured it out. Much of this
comes from the Novell gurus who hang out on Compuserve and know
everything there is to know about Novell.
The first thing you need to do is make up your mind that you are going
to do it right. The technique here might seem somewhat cumbersome, but
it works well and will keep you out of trouble.
MarxMenu has the ability to log you into a network, map your drives, and
set your environment strings without having to touch a Novell utility to
do so. MarxMenu can completely eliminate the need for Novell login
scripts. The advantage of using MarxMenu to login is that you have the
power of over 850 commands to work with instead of just 25 or so.
Computer Tyme * MarxMenu * Users Manual Page #28
-----------------------------------------------------------------
USING NOVELL'S LOGIN
For those of you who want to stay with Novell's login program here are
some tips to keep you out of trouble, and our tech support lines open.
The last command in your system login script needs to be EXIT "batch
name". This batch file will be the continuation of your login logic and
should end up jumping to the menu system. This is where TSR's can be
loaded.
Never load a TSR or run the menu from within a login script. Until the
login script finishes, LOGIN.EXE is in memory and it uses over 100k.
The first rule is don't use personal login scripts unless you have to.
The simpler the login, the easier it is to maintain. Try to do as much
as possible in the batch file you exit to.
MarxMenu can be run from this batch file as a post login processor. In
this case MarxMenu isn't being used as a menu but as a programming
language that is capable of very powerful login logic. The batch file
might look as follows:
MARXMENU POST.MNU
<load TSR's>
MARX MAIN
In POST.MNU you can set environment variables, test for directories,
write batch files, read user lists, map drives, or any number of things
that are useful to the login process.
THE CONFIG.SYS FILE
The place to start is the place where DOS starts when DOS boots. You
MUST create a CONFIG.SYS file on your boot disk. The CONFIG.SYS tells
DOS how many files and buffers to create, what device drivers to load,
and the size of the Master Environment.
Unless you are using special drivers, BUFFERS=40 and FILES=40 is a good
place to start. STACKS 0,0 will gain you an extra 3k of RAM. But the
most important command is the shell statement. A CONFIG.SYS file might
look like this:
SHELL=COMMAND.COM /P /E:400
BUFFERS=40
FILES=40
DEVICE=ANSI.SYS
This sets up enough environment space to allow MarxMenu and DOS SET
commands to work properly. You will also want to load any other device
drivers like QEMM386.SYS or 386MAX.SYS to take advantage of other
features of your computer. If you don't know about CONFIG.SYS files,
read the DOS manual.
Computer Tyme * MarxMenu * Users Manual Page #29
-----------------------------------------------------------------
Network Note: If you don't have a local hard disk and are booting from a
floppy drive, set BUFFERS=4. If you are booting from a diskless
workstation, set BUFFERS=1. BUFFERS are used for local drives only and
have no effect on network drives. You save 1k of memory for every 2
buffers you don't use.
THE AUTOEXEC.BAT FILE
After the CONFIG.SYS is loaded the AUTOEXEC.BAT runs next. Here you load
up your TSR's and network drivers. There are some important tricks to be
used here as well.
First of all, never load your network shell from your AUTOEXEC.BAT file.
Always have it branch to another batch file called LOADNET to load the
network shell. Use the AUTOEXEC.BAT only to load special TSR's and the
IPX. An AUTOEXEC.BAT might look like this:
@Echo Off
Cls
IPX
SET NET=NETX.COM
SET COMSPEC=O:COMMAND.COM
LOADNET
The two SET commands are very important. The first sets a variable
called NET to NETX.COM. This will be used later in LOADNET.BAT. By using
this variable, you can have users running many different versions of DOS
and still use the same LOADNET.BAT file. You could also use a command
SET NET=LOADHI EMSNETX.EXE to take advantage of advanced memory manager
software.
Another trick is to run BESTNET from the Network Survival Kit. BestNet
will automatically pick the best network shell and set the NET
environment variable for you. You would use the command BESTNET instead
of SET NET=NETX.COM in the AUTOEXEC.BAT file.
The SET COMSPEC=O:COMMAND.COM is important if you are booting off of
either a floppy drive or a diskless workstation. This assumes that O:
will eventually be mapped to a directory on the network that has a valid
COMMAND.COM in it.
It is important to set the comspec BEFORE loading your NET shell. This
prevents a problem where Netware wants to go back to the boot disk even
after you change the COMSPEC. We don't know why this works but it does.
Trust Me. If you are going to use COMMAND.COM on drive C:, ignore this
paragraph.
Now we go to the LOADNET.BAT file.
Computer Tyme * MarxMenu * Users Manual Page #30
-----------------------------------------------------------------
@Echo Off
%NET%
SET NET=
F:
STARTUP
The big concept behind LOADNET is that this file is NEVER CHANGED. You
put it on all your workstations and in the LOGIN directory and it is
EXACTLY THE SAME for every computer in your network. Any changes to
individual computers are made in the AUTOEXEC.BAT file.
So why is this important? Because if you are running diskless
workstations what happens is that while you are booting you have a
mythical drive A:. As soon as your NET shell loads this drive
disappears out from under you and you end up in F:\LOGIN. If you are
running LOADNET.BAT when this happens you drop out of A:LOADNET.BAT and
land in the middle of F:\LOADNET.BAT. And if your LOADNET.BAT is exactly
the same file as the LOADNET.BAT in the \LOGIN directory, you take off
running like the transition never occurred.
Even if you are not running on diskless workstations now, you might go
to it someday. It also creates good programming habits and helps you
boot up cleanly.
Let's see what LOADNET does. The first line is @ECHO OFF, that's easy.
The second line %NET% executes the network shell that you specified with
the SET NET=NETX command. This actually loads the network shell. The
third line clears the NET variable freeing up space for other
environment variables. F: switches you to drive F if you aren't there
already. And finally STARTUP is the name of yet another batch file you
jump to.
The STARTUP.BAT file controls what happens after LOADNET runs. This file
can be freely changed so that LOADNET.BAT can stay the same. This lets
you modify what happens AFTER the network shell is loaded.
If you are using Novell's login program STARTUP.BAT might look like
this:
@Echo Off
LOGIN
USING A MENU FILE TO LOG IN
If you are going to use MarxMenu to log in instead of Novell's
utilities, you will want to print out the sample file LOGIN.MNU on your
MarxMenu disk and study it. Your STARTUP.BAT file might look like this:
Computer Tyme * MarxMenu * Users Manual Page #31
-----------------------------------------------------------------
@Echo Off
SET BOOTUP=LOGIN
MarxMenu Login
%BOOTUP%
If MarxMenu works correctly, it will change the environment variable
%BOOTUP% to point to a file that it creates. If for some reason it fails
(you make a mistake in the login), it will execute Novell's login and
let you get in and fix it.
You will have to modify the LOGIN.MNU for your system. The one that I
supply will not work on your system. It is to be used as a sample only
and provide ideas for your login menu.
One word of caution. After modifying this menu, always run MARXCOMP
LOGIN to compile it. Otherwise, if you boot up into it you won't have
enough access rights to recompile automatically.
NOVELL SEARCH DRIVES
MarxMenu and Network Survival Kit files need to be in the search path.
You can copy the files into a directory that is already in the search
path or create a new directory and add it to the search path. Here is a
suggested setup.
---+--- SYSTEM
|
+--- MAIL
|
+--- LOGIN
|
+--- HOME -----+--- FRED
| |
| +--- BARNEY
|
+--- PUBLIC ---+--- DOS
|
+--- UTIL
|
+--- NSK
I would use MAP ROOT and set up the following mapped drives:
MAP ROOT H: = \HOME\BARNEY
MAP ROOT U: = \PUBLIC\UTIL
MAP ROOT N: = \PUBLIC\NSK ;Network Survival Kit
MAP ROOT O: = \PUBLIC\DOS
MAP ROOT P: = \PUBLIC
Computer Tyme * MarxMenu * Users Manual Page #32
-----------------------------------------------------------------
Set PATH=H:\;U:\;N:\;O:\;P:\;
The idea here is that the user's home directory is searched first, then
the UTIL directory where various network goodies and batch files are
kept. Then the NSK directory where only NSK and menu files are. Then the
DOS directory where only your original DOS files are. And finally PUBLIC
which contains only Novell utilities.
Traditionally, with Novell networks, searches have been set up using the
current directories of paths such as:
Set PATH=H:.;U:.;N:.;O:.;P:.;
I have found that since the addition of the MAP ROOT enhancement that
this traditional method is not as flexible.
NOVELL DRIVE MAPPING TRICKS
Many applications require a search drive mapped to the applications
directory. Instead of mapping every letter in the alphabet we have
discovered a trick. The idea is to create a floating drive letter that
you move into the application that needs it.
I map a drive W that I call my work drive. I initially set it to the
same directory as my home directory. But when I need an extra search
path I set it to point to the application as follows:
NovMapRoot('W','P:\WINDOWS')
Using this method it isn't necessary to modify your search path. You
always search through drive W but where W is moves with your
applications. If you need more than one extra search drive you can have
several floating drives.
You might want to include some drive mapping commands at the beginning
of your main menu to put the floating drives back to default
directories. This way you don't run into problems where a menu choice
doesn't work right after running another menu choice.
SETTING FILE ATTRIBUTES
Historically Novell has recommended setting file attributes to Shareable
and Read Only. This was to deal with DOS 3.0 and earlier and network
dumb programs. This is now an obsolete process and if you are in the
habit of doing this it's time to quit (unless you are still running DOS
version 2 on your workstations).
I personally flag all my network files Normal as a way of catching
network dumb programs.
Computer Tyme * MarxMenu * Users Manual Page #33
-----------------------------------------------------------------
MarxMenu is a network smart product. It therefore isn't recommended that
any file flagging be done on Computer Tyme software.
NOVELL SEMAPHORES
For a detailed explanation of Novell Semaphores, read the Novell
manuals. What we've done is to export these functions to MarxMenu. We
have implemented them slightly different than Novell did and have hidden
all the nasties from you such as semaphore handles. All semaphores are
accessed by name only.
Here's a brief overview of semaphores. Semaphores are names of shared
resources that the server keeps track of. Semaphores have three
properties. They have a name, value and number of users. The name can be
anything up to 48 characters long. The value is a number from -128 to
127. If the value is less than 0, the resource the semaphore represents
is considered used up.
By opening a semaphore, you increase the number of users by one. By
closing it, you decrease the number by one. If a single user opens a
semaphore many times, it is only counted as one. When you log out, your
semaphores are closed. This is also true if you turn your computer off,
but it takes 15 minutes for the server to give up on you.
The first user to open a semaphore creates it. The last user to close a
semaphore deletes it. When a semaphore is created, a value can be
assigned. If a semaphore is opened that already exists, the initial
value is ignored.
When NovWaitOnSemaphore is called by any user, the value is decremented.
If the value is not below zero, NovWaitOnSemaphore returns true.
Otherwise it returns false and the value is unchanged. The amount of
time that NovWaitOnSemaphore will wait is controlled by the variable
NovSemaphoreTimeOut.
When NovSignalSemaphore is called by any user, the value is incremented.
This allows other users to call NovWaitOnSemaphore and get a True value.
NovSemaphoreUsers and NovSemaphoreValue are used to read the status of a
semaphore without changing it's value.
One of the major differences between how MarxMenu uses semaphores and
the way Novell uses them is that normally a semaphore dies when the
application finishes. This would normally prevent a zero k menu system
from being able to use them. MarxMenu uses an interesting trick where it
fools Netware into thinking that the semaphore belongs to a TSR in
memory. This allows the semaphore to live.
Computer Tyme * MarxMenu * Users Manual Page #34
-----------------------------------------------------------------
Semaphores can be used for software metering. I've changed the
semaphores to work with TSRs in upper memory. You no longer need a TSR
in low memory for semaphores to live. This improves software metering.
USING SEMAPHORES FOR SOFTWARE METERING
An example of menu code that uses semaphores for software metering can
be found in the file METER.INC. This metering ability is limited to
Novell networks only.
This software metering module counts how many users are using an
application and limits it to a fixed number of users. Thus, you can save
money on other software by limiting the number of people who can run an
application to the number of copies you own.
This can also be used to limit an application to 1 user where the
application only works on a network for one user at a time.
To use this module, add the line INCLUDE 'METER.INC' to your menu. Then
under the OnKey you want to meter:
OnKey 'W'
|if Limit('WP',6) then Return ;limit to 6 users
WP
In the above example, a Word Perfect choice is limited to 6 users. Thus
you may have 20 users total but only 6 can run Word Perfect at the same
time.
The way it works is, MarxMenu creates a semaphore when it runs an
application and stores the semaphore name in an environment variable
named METER. When the user returns to the menu the semaphore is cleared.
If the user turns off their computer in the middle of an application,
netware will clear the semaphore within 15 minutes.
USAGE LOGGING:
OnKey 'W'
|LogIt('WordPerfect')
WP
This will send a log line to the log file that is a comma delimited
ascii line with fields as follows:
"UserName","Program","Start Time","End Time"
Computer Tyme * MarxMenu * Users Manual Page #35
-----------------------------------------------------------------
NETWARE MHS & MARXMENU
MarxMenu has the ability to interface to NetWare MHS which allows
MarxMenu to send and receive messages. You need to have a copy of
NetWare MHS to use this feature which can be purchased from your
friendly neighborhood NetWare dealer.
MHS stands for Message Handling System and the way it works is that you
have a dedicated mail transport computer on the network. This computer
is like a mailman and it goes around and looks for outgoing mail every
little bit. If it finds mail it reads the address and delivers it.
Any application program, such as MarxMenu, need only leave a text file
in a special outgoing directory and put an address header on the file.
Here's an example of how this is done:
Example:
var Message
{MHS Header}
AppendArray(Message,'SMF-70')
AppendArray(Message,'FROM:MARC @ CTYME')
AppendArray(Message,'TO:VICKI @ CTYME')
AppendArray(Message,'SUBJECT:The Princess Called!')
{Blank line separates header from message}
AppendArray(Message,'')
AppendArray(Message,'The Princess needs a ride home from dance')
AppendArray(Message,'class and wants to get some money to go')
AppendArray(Message,'skating. She wants to know if you can pick')
AppendArray(Message,'them up at midnight and if 5 little girls')
AppendArray(Message,'can stay over night.')
WriteTextFile(MhsSendDirectory + '\' + UniqueFileName,Message)
When MarxMenu creates a file in this format, MHS will pick up the file
and deliver it. When it's delivered it will be like any other message
and will appear in your favorite MHS Mail system. You can also use this
feature to notify you when your fax server receives a fax.
To receive a message, see the example under MhsReadFile. All MHS
commands start with Mhs. By using these MHS features, MarxMenu can be
used as a network job server that is triggered by messages sent to it
and reports it's results by sending messages.
Computer Tyme * MarxMenu * Users Manual Page #36
-----------------------------------------------------------------
UPGRADING MARXMENU
When installing an upgraded version of MarxMenu be sure to copy the
MARXMENU.EXE, MARXMENU.OVR and MARXCOMP.EXE files into your MarxMenu
directory. A very common mistake is not copying the MARXMENU.OVR file.
If you forget this file MarxMenu will lock up when you try to run it.
If you are on a network and anyone on the network is using the menu you
won't be able to copy over MARXMENU.OVR. You will have to wait until
after hours or chase everyone out of the menu to install the upgrade.
A common mistake occurs when you copy the MarxMenu file into a working
directory and someone else has the MARXMENU.OVR file open and you fail
to notice that it failed to copy. If MarxMenu starts locking up after an
upgrade this is probably why. Make sure the file dates on MARXMENU.EXE
and MARXMENU.OVR are the same.
After installing the new MarxMenu, all your menu files will have to be
recompiled. This should happen automatically, but if you are on a
network and the users don't have enough access rights the compile will
fail. You can recompile all your network menus as follows:
WHEREIS *.MNU|DOLIST MARXCOMP @L
If you are using MarxMenu to log into the network then be sure to copy
the new MarxMenu files into your LOGIN directory and recompile your
LOGIN menu.
If you install MarxMenu in one directory and then move it to another you
will have to run MARXMENU INST to recreate the batch files for that
directory. Make sure that the MarxMenu files are on your PATH.
Any time you upgrade, MarxMenu should work as well or better than the
previous version. Occasionally we make a mistak so you might want to copy
your present NSK directory to another temporary directory until the
upgrade is complete and tested. This gives you the ability to go back to
the old one should the need arise. This procedure should be followed on
software upgrades from other vendors as well.
CUSTOMIZING MARXMENU SAMPLE FILES
Included in the MarxMenu package are menu files which you can easily
modify to execute your programs and perform other functions you desire.
Using MarxEdit, the text editor included in this package, you can modify
and customize these menu files.
Also included to demonstrate the power and versatility of the menu
system is a game menu NIM.MNU. This is a game written in the menu system
that demonstrates some of the logic functions and programmability of the
system.
Computer Tyme * MarxMenu * Users Manual Page #37
-----------------------------------------------------------------
Here's a simple example of a menu file:
===================================
ClearScreen
DrawBox 30 9 25 8
Writeln ' 1) Lotus'
Writeln ' 2) dBase'
Writeln ' 3) Wordstar'
Writeln
Write 'Select: '
OnKey '1'
cd\lotus
123
OnKey '2'
cd\db3
db3
OnKey '3'
cd\wordstar
ws
====================================
Notice in looking at the "OnKey" statements that all you have to do is
tell MarxMenu how to get to the program. Although, MarxMenu takes care
of reloading itself after exiting a selected program, its does not
return to its own subdirectory as many other menu programs do.
That means that if you execute a program in another subdirectory, when
you come back to the menu, you remain in that subdirectory. If you
normally run your applications with a batch file, consider having
MarxMenu change directories and execute the program for you. This will
eliminate debugging problems caused by the actions of your batch files.
MENU ANALYSIS
Let's start a simple analysis of the example menu file shown above. The
ClearScreen statement simply clears the screen to give us a fresh
workspace for the menu. DrawBox is the command to draw a box on the
screen. The Writeln command writes a line of text to the screen within
the box, then positions the cursor on the next line. The menu text shows
the available selection keys that the user has access to.
Computer Tyme * MarxMenu * Users Manual Page #38
-----------------------------------------------------------------
ONKEY STATEMENTS
The OnKey statements control what is actually executed. OnKey statements
also allow you to execute hidden commands when you do not want them to
appear on the menu screen. One trick we use is to have an OnKey
statement define a key that runs MarxEdit on each users personal menu
file. We don't show this key on the menu to keep others from poking
around in the file. For additional security a password can also be set
up on this key.
Normally you enter a line of text as if you were creating a BAT file to
run your application. Like batch files, if one of your commands is a
batch file, all the statements after it will not execute. To prevent
this you can use the CALL command to call a batch file in DOS 3.3 or
later, or COMMAND /C in DOS 3.1 and 3.2.
Normally, text displayed under an OnKey statement is the same text as
the batch file created by MarxMenu. There are some exceptions: If a line
starts with a "|" (vertical bar), the line will be interpreted by
MarxMenu instead of being written to a batch file. This allows commands
such as "PASSWORD" to be used. String variables can be passed as part of
a batch command if the name of the string variable starts with a "%"
symbol.
The spaces preceding the commands under the OnKey statement are
for clarity only. They are not necessary for MarxMenu to function
properly.
Sometimes you need more control over what commands actually go into the
batch file that MarxMenu executes. You might want to input test from the
user or have the user make a choice from a list that will become part of
the batch file that is executed. The BAT command is used to do this.
Let's say you want the user to enter the name of a directory to back up
to a floppy. Here's how this might be done:
Example:
OnKey 'B'
|DrawBox 15 10 55 3
|Write 'Enter Directory: '
|BackupDir = Readln
|if (LastKey = Esc) or (not ExistDir(BackupDir))
| Return
|endif
|Bat 'XCOPY ' + BackupDir + ' A: /S'
DIR A:
PAUSE
Computer Tyme * MarxMenu * Users Manual Page #39
-----------------------------------------------------------------
Notice that the commands under the OnKey statement start with a vertical
bar. This is because they are MarxMenu commands rather than batch file
commands. Remember you are dealing with two languages here. MarxMenu
understands MarxMenu commands and DOS understands batch commands. When
you are under an OnKey statement all commands are written to a memory
buffer which are written to a batch file when MarxMenu exits. DOS then
runs this batch file. If you start a command with a vertical bar under
an OnKey command then MarxMenu will see the command.
The BAT command is a MarxMenu command that allows you to write lines to
the batch file that is being created. It allows you more specific
control of execution by allowing you to include MarxMenu variables in
the DOS command.
POPUP MENUS
If you want to create a popup menu within a menu you can do so by
using a "label". A label is a keyword preceded by a colon. To
call the popup menu, place the keyword on a line by itself
preceded by a carat (Shift 6). The label will precede the popup
menu definition.
For example if you have a popup menu to load Smart Software, you could
name the PopUpMenu Smart. To bring up the Smart PopUpMenu, define a key
in your main menu for Smart like this:
OnKey 'S'
^Smart
The Smart menu itself might look something like this:
:Smart
BoxHeaderColor ForeColor BackColor
BoxBorderColor Yellow Green
BoxInsideColor LCyan Green
InverseColor Yellow Red
BoxHeader = ' Smart Menu '
DrawBox 45 16 20 6
UseArrows 2 2 16 3
ClearLine 205
Writeln
Writeln ' Data Base'
Writeln ' Spread Sheet'
Write ' Word Processor'
OnKey 'D'
SM D
Computer Tyme * MarxMenu * Users Manual Page #40
-----------------------------------------------------------------
OnKey 'S'
|BoxHeaderColor ForeColor BackColor
|BoxBorderColor Yellow Green
|BoxInsideColor White Green
|%1 = PickFile('C:\SMART\SPREAD\*.WS',4,5,17)
SM S -ALOAD %1
OnKey 'W'
|BoxHeaderColor ForeColor BackColor
|BoxBorderColor Yellow Green
|BoxInsideColor White Green
|%1 = PickFile('C:\SMART\WORD\*.DOC',4,5,17)
SM W -ALOAD %1
While developing the menu, program one of the keys to run your favorite
editor on the menu file that you are creating. This way, as soon as the
change is made, the results will show when you exit your editor. Since
MarxMenu allows versatility in creating the look of your menus, a little
trial and error will be required to make things look right.
THE CONSOLE
+---| Console Functions |---+
| 1 - Blank Screen |
| 2 - Set Blank Message |
| 3 - Lock Keyboard |
| 4 - Set Blank Time |
+---------------------------+
The Console is a popup menu of built-in functions. To activate the
console, press the TAB key. A menu will popup in the upper
left-hand-corner of the screen. You can change the position of this
popup menu with the ConsolePos function.
The first command on the Console screen is Blank Screen. Enter 1 and the
screen will blank immediately. It will remain blanked until a key is
pressed. Enter 2 on the Console menu and you can change the message
displayed on the Blank Screen display.
Enter 3 and you will be prompted for a word to lock the keyboard. After
you enter the lock word the screen will blank and the keyboard will be
locked until the exact lock word is typed. Enter 4 to set the number of
minutes to wait before blanking the screen.
The lock word feature is handy for times when you must leave the
keyboard but don't want menu commands displayed for all to see. It also
effectively locks the keyboard so someone can't escape to DOS and test
the format command on your hard disk. We run this menu on a Novell
Network and don't want to let everyone have access to the Supervisors'
power at the touch of the escape key should we leave the keyboard.
Computer Tyme * MarxMenu * Users Manual Page #41
-----------------------------------------------------------------
REPOSITIONING THE TOP WINDOW
One nice feature you can use to play with the positioning of a window is
to turn on the scroll lock. This lets you move the top window around the
screen using the arrow keys so you can see how it looks. Then you can go
into your menu code and set it permanently.
Set Scroll Lock to "on". On most keyboards, a scroll lock LED will light
up. Now use the arrow keys to move the top window to any position on the
screen. Neat huh?
If you want to prevent users from moving the menus around using this
feature, add the command, "ScrollMove Off" to your menu.
MOUSE SUPPORT
If you have a standard mouse driver, MarxMenu will detect it and use it
automatically. The left button on the mouse is the same as pressing
return. The right button on the mouse is the same as pressing escape.
Pressing both buttons on the mouse is the same as pressing the tab key.
As of yet, the center button on the mouse is not used for anything.
The sensitivity of the mouse can be controlled using the MouseHorizontal
and MouseVertical commands or by setting environment variables MOUSEX
and MOUSEY.
STARTING OFF THE EASY WAY
For those of you who want to just get a menu going and don't want
anything complicated we have included a menu called the LEVEL1 menu.
This menu is a fill-in-the-blank type of menu that will get you going
quickly and easily.
This menu requires no programming and explains itself. You run it by
typing the command:
MARX LEVEL1
The first thing it does is scan your drive to find the directories. Then
you just answer the questions and fill in the menu. This isn't as
powerful as programming your own menu, but if you want something quick
and dirty, this may be the answer for you.
Although the LEVEL1 menu example will work on networks, it is mostly
intended for single user use.
Computer Tyme * MarxMenu * Users Manual Page #42
-----------------------------------------------------------------
ABOUT VARIABLES
One of the most unusual things about MarxMenu is its variables. MarxMenu
handles variables differently than any other programming language. For
the experienced programmer, this may require some adjustment since it's
like getting used to driving a Cadillac after driving a VW Beetle.
All variables in MarxMenu are like an empty box that can contain
anything. A variable can be a number, boolean, string, file, array, etc.
The type of variable is controlled internally and the user need not
declare variable types.
Variables are created with the VAR command:
Var X Y Z
If the word VAR is on a line by itself, the following lines, up to a
blank line, are considered variable names.
Var
MyAge
YourAge
HisAge
HerAge
Variables are initialized to null values; 0 for Numbers, False for
Booleans, and '' for strings. Initial values can be set when the
variable is created.
Var
X = 6
MyName = 'Marc'
Programmer = True
Variables can change variable types. If you write a number to a string
variable, the variable changes to a number.
X = '234'
X = Value(X)
This is valid in MarxMenu. X now is a number and contains the value 234.
When choosing variable names, it is good programming practice to choose
long meaningful names. This allows yourself and others to be able to
read menus and follow the logic more easily.
Computer Tyme * MarxMenu * Users Manual Page #43
-----------------------------------------------------------------
NUMERIC VARIABLES
MarxMenu supports two kinds of numbers, 32 bit integers and real
(floating point) numbers. Integers are whole numbers in the range of
plus or minus 2,147,483,647. This gives you a wide range of numbers but
no fractions.
With integers the answers to division are always rounded down thus:
7 / 3 = 2
Numbers beginning with a '$' indicate base 16 or hex numbers.
Example:
$20 is the same as 32
BOOLEAN VARIABLES
Boolean variables are True or False. For example:
var Adult
Adult = True
if not Adult then Write 'You must be 21 to enter.'
Boolean values can be set by computation:
Example:
Adult = Age >= 21
In this example the result of Age >= 21 is stored in the variable Adult.
If you use a boolean variable by itself, MarxMenu assumes you are
setting it to on. Thus:
ClearScreenOnExit
is the same as:
ClearScreenOnExit On
STRING VARIABLES
String variables are limited to 255 characters.
In MarxMenu, string literals are delimited by either single or double
quotes.
"This can't be yogurt!"
'Lincoln said "Four score and seven years ago ..." '
Computer Tyme * MarxMenu * Users Manual Page #44
-----------------------------------------------------------------
REAL NUMBERS
So what's the difference between ordinary numbers and real numbers?
Ordinary numbers in MarxMenu are 32 bit integers. These are numbers
whose range is about plus or minus two billion. Integers are whole
numbers and do not include any fractions.
This is why MarxMenu has included REAL numbers (also known as Floating
Point numbers). Real numbers in MarxMenu use BCD (Binary Coded Decimal)
with 18 digits of accuracy. They have a range of 10 to the plus or minus
63rd power, which means up to 63 zeros either side of the decimal point.
This lets you work with very big and very small numbers. MarxMenu has
smart rounding algorithms so that 1.0 / 3 * 3 = 1.0 and not
0.999999999999999999 like in most languages.
Real numbers are specified by using a decimal point. Thus 5.0 specifies
a real number. Most normal MarxMenu functions still require the standard
32 bit integers. If you get the error: 'REAL found where INTEGER
expected.' You need to use an integer.
If an integer is passed where a real is expected, the integer is
automatically converted to a real. Thus:
6.0 * 3 = 18.0
The Value function returns real numbers if a decimal point is used in
the string. All the relevant math functions will work with reals as well
as comparison operators.
MarxMenu supports a variety of functions for real numbers. It has trig
functions, log functions, and exponential functions. So why do you need
real numbers in a menu program? We don't know. The author had a library
and threw them in. We figure someone will need them someday.
With real numbers you can do trigonometry calculations like those
discovered by the ancient Indian chief Pythagoras who discovered what is
now known as Pythagoras's triangle.
Now we know that a lot of you were taught in Math class that Pythagoras
was Greek. Well, it's just not so. Here is the real story:
Pythagoras was an Indian chief who had three wives. Two of the wives
were twins and weighed 120 pounds each. And they sat next to Pythagoras
on a pair of twin deer hides. But Pythagoras also had a third wife who
was a large fat woman who sat across from Pythagoras on a hippopotamus
hide. This wife weighed 240 pounds.
What Pythagoras discovered was that the squaw on the hypopotamus was
equal to the sum of the squaws on the other two hides!
Computer Tyme * MarxMenu * Users Manual Page #45
-----------------------------------------------------------------
LOCAL VARIABLES
MarxMenu also supports local variables. Variables declared within
procedures become local variables. Local variables are just like global
variables in that you can use them as multidimensional arrays. When the
procedure finishes, all local variables are disposed.
If a local variable has the same name as a global variable, the local
variable will be used.
DATES
Dates in MarxMenu are stored as the number of seconds since January 1,
1980. This gives MarxMenu a date range of 68 years. By subtracting two
dates, you get the number of seconds between two periods of time.
MarxMenu has several commands that convert text strings to dates. Here
are some examples of how MarxMenu sees text dates.
Examples:
'4-7-91' ;04-07-1991 00:00:00
'April 7th, 1991 4:35pm' ;04-07-1991 16:35:00
'12:35:23a' ;04-07-1991 00:35:23
'3:15' ;04-07-1991 03:15:00
If the string can't be converted, then the variable BadDate is set to
true.
MarxMenu can also convert dates to strings by using the DateString and
TimeString commands.
PASSING PARAMETERS TO PROCEDURES
Procedures can accept parameters by declaring variable names on the same
line as the name of the procedure.
Procedures can return variables by using the Return command. Return
exits the procedure returning the parameters on the same line as the
Return statement.
Example:
Procedure Factorial (X)
var Y Z
Y = 1
Z = 1
while Y <= X
Z = Y * Z
Y = Y + 1
endwhile
Writeln X ' factorial is ' Z
EndProc
Computer Tyme * MarxMenu * Users Manual Page #46
-----------------------------------------------------------------
In this example, if you were to use Factorial (5) you would get:
5 factorial is 120
Another example:
Procedure AskYesNo (Question)
var YesNo
DrawBox (34 - (Length(Question) / 2)) 21 Length(Question) + 14 3
TextColor LCyan Blue
UseArrows Off
Write ' ',Question,' (Y/N) '
YesNo = UpperCase(ReadKey)
YesNo = YesNo = 'Y'
if YesNo
Write 'Yes'
else
Write 'No'
endif
Wait 50
EraseTopWindow
Return (YesNo)
EndProc
if AskYesNo 'Do you want to continue? ' then Continue
In this example, MarxMenu draws a box and asks a question and waits for
a "Yes" or "No" answer.
Arrays can be passed as parameters. Parameters are passed by value not
by reference. This means that any changes to the passed parameter do not
affect the original value.
You can copy an array by assigning it equal to another array.
Example:
Array1 = Array2
This creates Array1 with a copy of all the elements of Array2. The
previous contents of Array1 are overwritten.
ABOUT CONSTANTS
Constants are used to give values meaningful names. By using constants a
value can be assigned once and the constant name used throughout the
menu program. This way, if you change the value of the constant, all the
places where that constant is used automatically change.
Computer Tyme * MarxMenu * Users Manual Page #47
-----------------------------------------------------------------
This is good programming practice.
Examples:
Const States = 50 CPU = '80386 SX' WeekEnd = True
or
Const
States = 50
CPU = '80386 SX'
WeekEnd = True
Using the word STATES is just like using 50. Using CPU is just like
using '80386 SX'. But if throughout my menu you use CPU, and then you
get a new computer with a 80486, you can just change one line:
Const CPU = '80486'
And all the places you used CPU changes to '80486'. This is the correct
way to program.
ABOUT ARRAYS
MarxMenu supports multidimensional arrays up to 31 dimensions. Unlike
other programming languages, arrays need not be declared. MarxMenu
creates arrays "on the fly" and automatically takes care of the array
size and number of dimensions.
Another unusual feature of MarxMenu arrays is that they are an array of
MarxMenu variables. This means that elements of MarxMenu arrays need not
be of the same type. Element 1 can be a number, element 2 can be a
string and element 3 can be another array.
This type of variable management leads to the easy creation of very
powerful data structures as you will see.
Var X
X[1] = 'Element 1'
X[2] = 3
X[3] = True
X[4,6] = 9
X[4,7] = 'Ten'
These are all valid statements. MarxMenu creates a two dimensional array
here. If we now execute the following statement:
Computer Tyme * MarxMenu * Users Manual Page #48
-----------------------------------------------------------------
X[4] = X[4,6] + X[2]
X[4] becomes equal to 12 but variables X[4,6] and X[4,7] are lost. This
is because we have changed an array into a number. MarxMenu
automatically handles the deallocation of memory used by this array and
its elements and returns the space the used to the memory pool.
ABOUT QUALIFIERS
Qualifiers are named indexes into arrays. They are used to make the
source menu file more readable and more organized.
Suppose we are creating a data structure to deal with places in the
United States. First we will need an array for States.
Var States
We want to store some facts about the states.
Qualifier
Population
Bird
Motto
County
State[3].Population = 10000000
State[3].Bird = 'Chicken'
State[3].Motto = 'Best politicians money can buy!'
Now states have counties and counties have county seats, sheriffs, and
cities.
Qualifer
Sheriff
Seat
City
State[3].County[7].Sheriff = 'Buck InBred'
State[3].County[7].Seat = 'Possum Trot'
Now counties have cities and cities have schools, mayors, churches, and
taxes.
Qualifier
Schools
Mayor
Churches
Taxes
Computer Tyme * MarxMenu * Users Manual Page #49
-----------------------------------------------------------------
State[3].County[7].City[9].Schools = 8
State[3].County[7].City[9].Mayor = 'Virgil Collins'
State[3].County[7].City[9].Churches = 120
State[3].County[7].City[9].Taxes = '$100,000,000'
The above line is the same as:
State[3,4,7,3,9,4] = '$100,000,000'
As you can see with qualifiers, it is easy to create multidimensional
arrays in a way that is organized and readable.
In this example, the qualifier Population became equal to 1. Bird became
equal to 2. The variable references, State[3].Bird and State[3,2] are
the same. It's just that one is more readable than the other. Qualifiers
normally begin by assigning 1 to the first name and 2 to the second,
etc. This can be modified.
Qualifier
Color = 7
Size
Shape
In this case Color becomes the number 7; Size becomes the number 8; and
Shape becomes the number 9.
POINTER VARIABLES
In MarxMenu, variables can point to other variables allowing parameters
to be passed to procedures by reference as well as by value. A pointer
variable stores the location of another variable. Any time a pointer
variable is accessed, MarxMenu acts upon the variable that the pointer
variable is pointing to. Pointer variables are set using the Loc
(location) command.
Example:
Var A B C
A = Loc B
MarxMenu supports complex location pointers and pointers to other
pointers. MarxMenu will resolve all references until real data is found.
Example:
B = Loc A
C = Loc B
C[5] = 20
Writeln A[5] ;returns 20
Computer Tyme * MarxMenu * Users Manual Page #50
-----------------------------------------------------------------
Pointers can also be passed as parameters to procedures. Thus if A is an
array of strings we can sort A as follows:
Procedure SortTest (TestArray)
SortArray(TestArray)
EndProc
SortTest (Loc A) ;sorts array A
COMMENTS IN MENU FILES
MarxMenu has three ways to add comments to a menu file. The first way is
with the Comment command.
Comment
========================
This is a comment block.
========================
EndComment
All lines up to EndComment are ignored.
The second way is with a ';'. All text to the right of the ';'
(semicolon) is ignored.
BlankTime = 20 ;this is where we set the blank time.
The third way is using {} or curly braces. Anything inside the curly
braces is ignored. Curly braces can be nested.
{All of {this} is a comment.}
Comments are ignored by the compiler and cost you nothing in execution
speed. Comments can save you a lot of time if you have to come back
later and work on your menu, or if someone else has to work on it.
Therefore, we encourage you to use comments as much as possible.
THE MARXMENU COMPILER
MarxMenu reads your MNU files and creates MRX files. These MRX files are
a highly digested form of the MNU file that you created. MRX files are
the compiled files.
When you run MarxMenu, the interpreter MARXMENU.EXE looks for the menu
file with the MRX extension. If it doesn't find it, MARXMENU.EXE will
automatically load MARXCOMP.EXE and compile the menu. MARXMENU.EXE also
compares the file dates of the MNU and the MRX files. If the MNU file is
newer than the MRX file, the compiler will be loaded.
Computer Tyme * MarxMenu * Users Manual Page #51
-----------------------------------------------------------------
MarxMenu will also force a compile if the MRX file was not compiled by
the same version and release date of the MarxMenu you are using. MRX
files are not compatible from one version of MarxMenu to the next.
You can also force a compile from the command line by typing MARXCOMP
<menu>. If you are on a network and using MarxMenu to log you in, make
sure you run the compiler if you change your login menu file.
Once your menus are written, you can remove the MNU file and
MARXCOMP.EXE from the system. This prevents anyone from modifying your
menus. The MRX files are scrambled for security. This prevents probing
eyes from reading strings in the MRX files.
One important thing to remember. Don't lose your original MNU files. The
MRX files CANNOT be decompiled. If you lose your original menu files
you can't change your menus and the MRX files you have will not be
compatible with future releases of MarxMenu.
MARXMENU LANGUAGE RULES
MarxMenu interpretation is left to right and doesn't have any operator
precedence. You can control the order of evaluation by using
parentheses.
Examples:
2 + 3 * 4 ;returns 20
2 + (3 * 4) ;returns 14
if A > 4 or B < 6 then ... ;error
if (A > 4) or (B < 6) then ... ;correct
Statements are limited to one line and lines are limited to 200
characters.
COMPILER COMPATIBILITY
The MarxMenu compiler is fully compatible with earlier versions of
MarxMenu with a few exceptions. The new compiler does a lot more error
checking than earlier versions of MarxMenu and will catch errors that
you could previously get away with. Other than that, the only difference
you should notice will be a speed increase.
Earlier versions of MarxMenu had separate names for variable types. The
names $VAR, BVAR, #VAR, and FILEVAR act the same as typing VAR.
Very early versions of MarxMenu had a different form of the USEARROWS
command that required 4 to 5 numbers after it. If you run into this
error, just get rid of the numbers after USEARROWS and it will work
fine.
Computer Tyme * MarxMenu * Users Manual Page #52
-----------------------------------------------------------------
A WORD ABOUT DOS VERSIONS .....
Versions of DOS below 3.3 will cause MarxMenu to use 3.5k of RAM where
3.3 DOS and above use no memory. 3.2 DOS is very buggy and should be
replaced. 3.1 DOS isn't too bad for bugs but if you're using the BACKUP
and RESTORE programs that came with it, you're in trouble. They don't
work on large files. You'll find that out if you try to restore one of
them.
MS-DOS 4.01 seems to be pretty clean provided you have the April '89
release or later. To determine if you do, check the file date on
COMMAND.COM. Earlier versions of DOS 4.01 have SERIOUS BUGS. If you are
running any DOS 4 earlier than April '89 you should upgrade immediately.
We are happy to announce that MarxMenu runs under DOS 5.0 with no
problems or modifications. One feature implemented is the Idle Loop call
which allows MarxMenu to conserve CPU power when it's not doing
anything. This makes it work better under DesqView and Windows.
Speaking of Windows, MarxMenu is not a Windows program. It can however
be used to start Windows programs and can be run under Windows. Windows
however is an extremely unstable environment. If for some reason you're
having trouble with MarxMenu and Windows, it's Windows fault. In spite
of glowing reviews that magazine writers seem compelled to write, I
recommend avoiding Windows unless you have a program that requires
Windows to run.
DR-DOS or EZ-DOS are pretty good also. It is very compatible as long as
you don't get too strange with it. We recommend version 3.4 or later.
DR-DOS has a nasty COMSPEC bug in versions 5 and 6 when running a second
COMMAND.COM shell started from a network drive.
4DOS is also pretty good but sometimes some of the advanced features in
this product can cause it to behave differently than DOS. This requires
extra care when writing your menus.
MarxMenu should work correctly on 386 multiuser operating systems such
as Digital Research's Concurrent DOS 386 or SCO VPIX DOS emulators and
PCMOS. Under these systems you will have to set the TASK environment
variable if you are running MarxMenu in multiple tasks.
MarxMenu will not run correctly under DesqView 2.26. It will run under
2.25 or 3.21. So if you are running 2.26, it needs to be upgraded.
MarxMenu contains several support functions for DesqView including
DesqView API calls to control the DesqView environment.
Although we haven't tested MarxMenu in the OS/2 1.3 compatibility box, we
have had good success with MarxMenu under OS/2 2.0. We have been able not
only to run DOS programs but OS/2 programs as well. If set up right
MarxMenu can spawn multiple tasks of both DOS and OS/2 applications.
Computer Tyme * MarxMenu * Users Manual Page #53
-----------------------------------------------------------------
If you are running under some weird DOS and are having problems, try it
under "regular" DOS and see if it goes away. If it does, try to find out
what it is about your weird DOS that makes it not work right. We are
interested in being compatible with as many systems as possible. Let us
know if you are having problems. But also, try to get your weird DOS
vendors to clean up their act.
A WORD ABOUT BUGS .....
Although we try to create perfect bug-free software, every now and then
we make a mistak. If you find one, let us know and we'll fix it. Our
standard is to not only have all the functions of MarxMenu work
correctly, but for it to be as intuitive and full featured as possible.
TIPS FROM THE MASTER
Since MarxMenu is a programming language, I want to talk about what
programming is and how it is accomplished. I want to dispel some myths
and fears relating to it and introduce you to techniques that will help
you write code neatly, quickly, and efficiently. From the outside,
programming looks like magic; but once you know a few of the tricks, it's
really not too hard.
Many of us who were raised on 50's and 60's science fiction television
learned that it is the brainy types who deal with computers. It almost
gives you the impression that the computer is smart and you are dumb. As
you use the computer, it is evaluating you, and if it figures out that
its smarter than you, it can get your job and replace you.
COMPUTERS DO SIMPLE TASKS
A computer is a simple device. It does simple tasks. It just does them
very fast and accurately. Computers don't even know basic things like
how to write letters on the screen or how to read the keyboard. These
are programs that the computer runs. Someone had to program your
computer to do even the simplest of tasks.
As you learn to use MarxMenu start with the simple menus. The SAMPLE.MNU
is a very easy program. Study it and understand how it works. Make a
copy of it and begin by changing a single selection to run one of your
programs.
Once you have changed one selection, change several more. Now MarxMenu
is running your programs, and you have made it work. Then try something
new. Add more selections. Change the size and position of the box to fit
your needs.
Take the time to play with it. Try new commands. Build up your menu. Be
artistic. The more you work with it, the more you will learn.
Computer Tyme * MarxMenu * Users Manual Page #54
-----------------------------------------------------------------
COMPLEX TASKS ARE MADE OF SIMPLE TASKS
As you learn more about MarxMenu, move on to QUICK.MNU. Here we use more
of the power of the MarxMenu language. As you study this menu, you will
notice something. Even though it looks complex, it is really a
collection of simple tasks. Understand how the moving windows work.
Understand that the pop-up menus are just like the main menu. You will
see that it is really not a complex menu at all. It is a lot of simple
processes hooked together.
That is one of the main concepts behind programming. Complex tasks are
built out of simple tasks. As you learn the simple tasks, you will
quickly understand how to connect them to accomplish complex tasks.
When one sees a castle, one can't help but to be impressed. But castles
are made of stones. And you can't build castles until you understand how
stones work. Then you realize that a castle is just a bunch of stones
hooked together. Programming is just like that.
To successfully understand MarxMenu, start at the bottom and work your
way up. Each little trick you learn becomes another building block for
the next trick. What you start with becomes the foundation for the work
that you will eventually produce.
LEARNING GOOD PROGRAMMING HABITS
Programming has its pitfalls, here we hope to give you some tips that
will help you avoid common mistakes. This, we hope will give you a head
start on the road to MarxMenu being done right.
The first concept is patience. Rome wasn't built in a day. You may not
be able to write grand and glorious menus the first try. In fact, you
may have trouble getting the damn thing to work at all. As you have
probably already noticed, no program is perfect. Sometimes there are
errors in the manual. Sometimes it just doesn't work like you expected,
or does not work the same way as other programs that are familiar to
you.
But, once you complete the installation, give it some time and realize
that there is a lot of potential here. Approach all challenges with a
good attitude.
USE LONG NAMES
I learned computers the hard way. Out on the streets. Hanging around
with other computer nerds in the late 70s who never went to college
either. I was known as a Bit Wit. My first real computer was an IMSAI
kit. Actually, it wasn't all IMSAI, it was a combination of several kits
where no two boards came from the same supplier. It was in an IMSAI box,
so I called it an IMSAI.
Computer Tyme * MarxMenu * Users Manual Page #55
-----------------------------------------------------------------
It was all supposed to work together the salesman told me the day
before they went out of business. And it all did after some redesigning.
I was tired of fixing CB radios for a living and decided that
computers were here to stay and that I was going to learn about them.
With that in mind, everything that went wrong became an opportunity for
growth. Not that I looked forward to things not working. I programmed
the thing from scratch, loading binary codes into memory from an array
of switches on the front panel.
The first program I developed ran the EPROM burner, which was the only
storage device I had. After I saved this program on a chip, I used it
to load the second program onto the chip.
Eventually I wrote enough software to talk to the screen and keyboard.
Now I could type hex codes on the screen and save them to a chip.
Eventually I wrote a tape driver and could save stuff on tape. Later, I
traded for a North Star disk drive and had a disk system. One 90k
floppy. I thought I was in heaven.
I was intimately familiar with my computer. All my programs were in
object code with no documentation whatsoever. At that point, a friend of
mine, Rufus, turned me on to a language called FORTH.
Being an interesting language and very powerful, I typed in the whole
compiler in hex and adapted it to work on my system. Once I got Forth
up, I wrote a line editor in it. Then I used the line editor to write a
screen editor. With the screen editor, I rewrote Forth in Forth. The
language compiled itself.
From working with Forth (which is as much a religion as a programming
language) I learned both good and bad habits. Forth is a write-only
language and is almost impossible to read even with the best of
documentation. On the other hand, it is as close to the machine as you
can get in a high level language.
After opening up a computer store in 1984, it became time to make the
jump from CP/M to the DOS world. Turbo Pascal offered an interesting
solution. They had both a CP/M and DOS compiler. This meant that
programs I wrote would run on both machines. The thing that struck me
about Pascal was that I could read it better than Forth, and didn't
even know the language. Not only that, but I could follow the programs
that other people wrote and incorporate their code into my code.
The more programs I wrote, the more I came to appreciate a language that
was reader friendly. I could manage my programs much easier without
having to remember so much. Other people could follow what I was doing
easier.
Computer Tyme * MarxMenu * Users Manual Page #56
-----------------------------------------------------------------
The important thing I learned was that readability is very important in
a program. The more complex the program, the more important readability
becomes.
One of the main design factors in the MarxMenu language is readability.
I could have used short names for the commands and it's not like I
like to type. I'm still on just two fingers here. It's just that
descriptive names are so much more meaningful when putting simple
processes together to create complex processes.
The point (finally) is, when creating variable names, or procedure
names, use long meaningful names. It may take more typing, but it takes
a lot less thinking and remembering later on. Consider the following
example in choosing variable names.
Var KlingonsDestroyedInBattle
Var K
In the above example, it is obvious which one tells you more about what
information is stored in the variable.
USE COMMENTS LIBERALLY
Even though MarxMenu is easy to read, it still should be commented. The
examples that come with this disk do not have as many comments as they
should. Don't do as I do, do as I say. I'm lazy and a bad example.
Comments are not compiled in your MRX files and cost you nothing at
execution time. In order to make commenting easy, we have provided three
separate comment commands. Learn these commands first.
Every menu should include a title comment. This should include the name
and phone number of the person who wrote it. If you have a problem with
a menu and you send it to us, we expect a title comment. That way we can
call you about it.
Comment
====================================================================
This comment was created by Marc Perkel 1-417-866-1222
Last Updated: 01-28-90
This form of comment block is better than using ';' because not using ;
allows you to turn your word wrap feature on and do some professional
looking editing in the comment block. This kind of comment block should
be at the beginning of each and every menu you create.
Computer Tyme * MarxMenu * Users Manual Page #57
-----------------------------------------------------------------
The top and bottom bars are for looks only and are not necessary to the
comment. I strongly encourage you to use bars and do things for looks
in source code. Looks are very important and you should put as much
care into your comments as you do in writing a business letter.
If you learn MarxMenu well, your source code may be part of your next
job interview as you move up the corporate ladder. So you want it to
look good.
By the way, if you upload your menus to my bulletin board, I expect a
comment block at the top of your menu with your phone number so I can
get back to you.
====================================================================
EndComment
INDENT YOUR CODE
As programs get more complex, it gets harder to match the IFs with the
ELSEs and the ENDIFs. This is where indenting comes in. It creates a
logical grouping of statements and you can easily see what goes with
what.
Procedure IfDemo
IF <condition>
<statement>
<statement>
ELSEIF <condition>
<statement>
ELSEIF <condition>
<statement>
<statement>
ELSE
<statement>
<statement>
WHILE <condition>
<statement>
<statement>
ENDWHILE
<statement>
ENDIF
<statement>
EndProc
You can easily see how this helps you follow what you are writing. Now
here's a new trick. If you are using an IF, and plan to use an ELSE and
an ENDIF, on the line under the IF statement, type in your ELSE and
ENDIF lines. Then go back and insert your statements in between these
lines. This will help you avoid forgetting the ENDIF or getting mixed up
as to which IF matches which ELSE.
Computer Tyme * MarxMenu * Users Manual Page #58
-----------------------------------------------------------------
A similar trick can be done with parens and brackets. When typing a left
paren, type the matching right paren with it. Then fill in the code you
want to put inside the parens or brackets.
FOR DUPLICATE TASKS, USE PROCEDURES
As menus become longer and more complex, many times you are duplicating
a process that you have already written. Although it is easy to copy a
block of code, it is better to create a procedure.
With procedures, the process is put in one place and is given a name.
Preferably a long meaningful name. Once this procedure is defined and
named, it can be used as if it were part of the MarxMenu language. This
makes menus smaller and easier to read. It is also a way for you to
combine small processes into large processes. Procedures can be built
using other procedures.
Once you have a process figured out and working in a procedure, the
whole process becomes a black box with a name that you can use
elsewhere. The whole process is reduced down to a name that just works!
Another advantage of procedures is that if circumstances change and the
procedure needs to be modified, you only make a change one place in your
menus, and everything that uses that procedure is automatically changed.
This makes menu maintenance easier.
DON'T PROGRAM YOURSELF INTO A CORNER
Using the above techniques will allow you to write very complex menu
systems. Failing to use these techniques can limit what you can
accomplish. There is a term called "programming yourself into a corner"
which refers to a program that is so poorly written, that it can't be
modified to accommodate changes and improvements.
The height of your programming abilities depends on the foundation on
which they are built. You must avoid rushing to the top without first
creating a firm foundation on which to build. Good technique is the
foundation for good programming. You will have to learn it eventually,
it is more efficient to do it right than it is to do it over.
Adopting good programming habits reminds me of my favorite light bulb
joke:
Q. How many psychologists does it take to change a light bulb?
A. Only one, but the light bulb has to want to change.
Computer Tyme * MarxMenu * Users Manual Page #59
-----------------------------------------------------------------
FOR THE POWER USER:
I originally wrote MarxMenu on a dare. I said that in one afternoon I
could write a better menu system than one of the most popular menu
systems. I met the challenge and then found that there is a lot of
demand for power in a menu system. Friends started asking for this and
that feature and this program has gone far beyond what I ever intended.
The demand for more features has outpaced my ability to keep up with the
documentation standards that I expect from other software packages that
I buy. Please bear with me; If you find any errors in the manual, or
bugs in the program, please let me know and we'll try to correct any
problems.
I also appreciate your suggestions for improvements. Many of the
features included are a result of requests you have made. Many of you
are using this program in ways I never dreamed.
The main design philosophy behind this product is POWER and Flexibility.
I am also committed to keeping the source code as readable as possible.
I am loyal to the concept of using NO RAM. None of MarxMenu stays
resident. Because of this I can claim that if you are having some kind
of problem, it's not the fault of MarxMenu being resident, because
MarxMenu is not resident. Also, using NO RAM allows loading of TSR's
(memory resident programs) from the menu.
For computer consultants, MarxMenu is an excellent way to make money.
You can provide your clients with professional looking menu systems
customized (by you) to fit their needs. You can provide complex menu
structures not possible with any other menu system. And, because
MarxMenu uses NO RAM, you don't have to worry about conflicts between
MarxMenu and any other software product.
Although MarxMenu is copyrighted, the program is not copy protected.
There is nothing to prevent you from making hot copies and giving them
away to all your clients. I would like to point out that when you give
away something you should be selling you lose respect from your clients
and attract those who expect you to work for free. You will make more
money if you play by the rules. My best and most profitable clients use
no hot software whatsoever. Think about it.
WHERE MARXMENU IS HEADING
MarxMenu will continue to grow and develop. Because MarxMenu is an
overlaid program I have the ability to add as many features as I want
without slowing down load or processing speed. In fact MarxMenu is 10
times as fast today as it was in 1989 and its vocabulary of commands has
grown 20 times as well.
Computer Tyme * MarxMenu * Users Manual Page #60
-----------------------------------------------------------------
Most of the new features I add to MarxMenu are a result of your
requests. Feel free to call me and make suggestions as to what you want
to see in MarxMenu. Often my biggest problem in adding new features is
getting companies to release information. Thus, if you want something
new and I have to go to IBM, Novell, or Microsoft to get information
sometimes it takes a while. So if you have any pull with some of these
vendors and will help me put the squeeze on them, I'd appreciate it.
I'm often asked the question, what other operating systems will I
support? Will there be a Windows version? An OS/2 version? Unix?
Let me say first that my primary commitment is to the OS that most
people actually use, and that is DOS. I am not moved by the industry
politics. I focus on the systems that make computers and networks
actually work.
So for those of you who are asking the question "Will there be a Windows
version of MarxMenu?" The answer is no. The reason is, in my view,
windows is too unstable a platform in which to develop code for. As I
see it, Windows is a programmer angry environment and is fatally flawed
by design. I consider this path a mistake and a mistake that I am not
going to make.
Will there be an OS/2 version? No. IBM made a lot of promises that they
didn't keep. I lobbied hard to get IBM to add some features to OS/2 to
allow DOS programs to control the OS/2 environment and talk to the OS/2
kernal. This would have allowed MarxMenu, as a DOS program to control
OS/2 programs. The response was that IBM wants people to move away from
DOS and refused to add the necessary features. The Borland compilers
that were supposed to be ready when OS/2 was released don't exist.
Will there be a Univell version? Maybe. If Novell doesn't make the same
mistakes as IBM and Microsoft have and provide a migration path then
maybe there will.
A WORD TO WRITERS AND REVIEWERS
MarxMenu is a multi-level product fulfilling the needs of a large
variety of computer users. It is difficult to compare this product on a
feature-to-feature basis. This is because MarxMenu has about 10 times as
many features as any other menu system. These features allow this
product to target a very broad variety of computer users, from the
novice user, who will only use the LEVEL1 or QUICK menus, to large
companies with hundreds of file servers controlled through the MarxMenu
language.
One common mistake that writers make when evaluating MarxMenu, is in the
area of ease of use. If you are looking for ease of use, stick with the
simple menus and the self-configuring menus such as the LEVEL1, QUICK
and QUICKNOV examples. By looking at it this way, MarxMenu will be as
easy to use as any other menu system out there and can be compared for
similar features. Even though MarxMenu supports complex commands, it is
not necessary to use them in simple menus.
Computer Tyme * MarxMenu * Users Manual Page #61
-----------------------------------------------------------------
If you are doing a comparative review, please let us know on what basis
you are making comparisons. This way we can assist you by providing you
accurate information in the area of your interest. If you are looking
for simple, we can show you simple; if you are looking for power, we can
show you power.
On the other hand, if you are reviewing power tools and network
utilities, you might want to look at the Network Survival Kit and not
just MarxMenu. So if you only have a copy of MarxMenu, give us a call
and we will get you the latest and greatest.
In addition to our software, we also have color prints and color slides
available as well as product literature and sample reviews. These are
available to make your job easier and help you make those deadlines.
MarxMenu tends to be best reviewed as a long article rather than a short
one. It is very good if you have a lot of space to fill. With a long
article, you can get really in depth with what MarxMenu is able to do.
Any publication which reviews any of my products gets a site license to
that product whether we like the review or not. Our position is that if
you are using MarxMenu yourself, you will get to know it better.
Any questions you have about any of my products, feel free to call. The
main thing we ask is that you get the product name, price, our address,
and our phone number right.
SECURITY ISSUES
Different users have different security needs that range from none to
extreme. If you are in the none category, then you can skip this
chapter. But if you need all the security you can get, then read on.
First of all, DOS is not a secure operating system. There are various
third party programs out there but what I'm going to cover here is how
to make DOS secure as possible working with what you get with DOS.
The first thing to do is add the command BREAK=OFF to your CONFIG.SYS
file. This prevents programs from breaking out of batch files. Avoid
using commands that are internal DOS commands like DIR from inside a
menu or inside batch files. Use the D.EXE program instead.
Use the LockWord option in the screen blanker so that if a menu is left
unattended, it will not be accessible to just anyone walking up to a
machine. The LockWord command requires the user type a password to
release the screen blanker. If you are on a Novell network, you can use
the UseNovPassword command. This forces the user to type their Novell
password to unblank the screen.
Computer Tyme * MarxMenu * Users Manual Page #62
-----------------------------------------------------------------
If a menu choice accesses sensitive materials, then put a password on
it. Also, make sure the SUPERVISOR user has a password. There are many
times I've walked up to a server and logged in as supervisor and got
right in. Make sure that intruder detection is set on. If you don't know
what intruder detection is, read the Novell manuals.
You can also use the LogoffTime command to log users off the network
after a given amount of inactivity. This also helps kick people off so
that you can upgrade MarxMenu from time-to-time. (MARXMENU.OVR can't be
updated on a network unless all users are out of the menu.)
If you have applications that allow you to shell to DOS, you can prevent
them from getting to DOS by changing your COMSPEC to point to something
other than COMMAND.COM. You could also rename COMMAND.COM in case a
program is looking for this file by name. If this doesn't work for you
then you can use the COMSP.EXE program to do the same thing.
Another defense is to lock the door to the computer room at night and
teach employees security policies and make sure they use them. Security
policies include such rules as not having your password written on a
stick-em note stuck on the side of your monitor.
If you are on a network, buy diskless workstations. People can't copy
files on or off a workstation that doesn't have a disk drive. It helps keep
viruses off your server and lets the network administrators control what
is and isn't on the network.
KEEPING USERS IN THE MENU
Some people need to keep users in the menu and prevent them from
escaping to a command line no matter what. There are several things you
need to do to accomplish this. The first thing is to use BREAK.SYS to
prevent breaking out of batch files. Then you use a shell statement to
load COMMAND.COM temporary instead of permanent. Then you use COMSP.EXE
to prevent programs from shelling out to DOS.
USING BREAK.SYS
MarxMenu comes with a device driver called BREAK.SYS. This program
enhances the BREAK ON and BREAK OFF functions of DOS to prevent users
from using CTRL-C to get out of batch files.
Unlike all the other similar programs this one is smart. It only kills
CTRL-C if you are in COMMAND.COM but allows your applications to see
CTRL-C. And, it only uses about 400 bytes of RAM.
All you have to do is add a line to your CONFIG.SYS file:
Computer Tyme * MarxMenu * Users Manual Page #63
-----------------------------------------------------------------
DEVICE=BREAK.SYS
If you are using BREAK.SYS with QEMM or other memory manager, load the
memory manager first.
BREAK.SYS can be enabled or disabled by using the BREAK ON and BREAK OFF
commands either from the command line or from batch files.
Although BREAK.SYS is better than DOS, it isn't perfect. There are still
situations where you can break out of batch files. If it is important
not to break out then you can use it as follows:
DEVICE=BREAK.SYS /C
Using it this way the CTRL-C key is completely disabled. Your
application software will not get any CTRL-C.
BREAK.SYS has another switch /T that works like /C except that once you
execute BREAK ON then it returns to smart CTRL-C handling. The idea here
is that more often you need bullet proof protection while the system is
booting up, but after going to the main menu you can switch to smart
protection. At the end of your bootup batch files add the lines:
BREAK ON
BREAK OFF
This will switch BREAK.SYS into smart mode checking.
BREAK.SYS has another feature that makes BREAK ON work better. If you
use it like this:
DEVICE=BREAK.SYS /B
Then when you run BREAK ON and the users presses CTRL-\ it will break
you out of programs you might otherwise be stuck in. This feature is
great for software developers to use when testing code.
USING THE SHELL= COMMAND
If you really want to make it impossible to break out to DOS then change
the SHELL= statement in your CONFIG.SYS file to read:
SHELL=COMMAND.COM /E:400 /C AUTOEXEC.BAT
With this command, if they get out of the batch file it locks the system
up. In some cases this is better than letting the user get access to the
command line.
Computer Tyme * MarxMenu * Users Manual Page #64
-----------------------------------------------------------------
To use this feature you need to stay in a steady stream of batch files
all the way to the menu. If you ever exit or break out of the batch
files the system locks up. Without the /P switch, COMMAND.COM is never
loaded permanent. So if AUTOEXEC and the batch file that they jump to
ever finishes the computer locks up. You can't break out to COMMAND.COM
because there is no COMMAND.COM to break out to.
If you try to use this with Novell's LOGIN.EXE then you won't be able to
use the 'EXIT <string>' command in your login script. This is because
EXIT will exit to DOS and lock up. You will need to create a LOG.BAT
file as follows:
LOG.BAT
=======
:Start
LOGIN
REM ** Stay in loop till LOGIN succeeds **
if ErrorLevel 1 goto Start
...
<other startup commands>
...
Marx MainMenu
To get to a command line using this system you will need to run
COMMAND.COM or DOLIST.EXE from the menu. In the case of COMMAND.COM you
will run:
COMMAND.COM /E:400
This ensures that this second COMMAND.COM has enough environment space
to allow for SET commands.
CONDITIONAL STATEMENTS
MarxMenu has a full complement of conditional statements. They are as
follows:
IF->ELSE->ENDIF Where, IF [condition]
statement
statement
ELSE
statement
statement
ENDIF
IF->THEN Where, IF [condition] THEN statement
IF->ELSE->ELSEIF->ENDIF Where, IF [condition]
statement
statement
ELSEIF [condition]
statement
statement
ELSEIF [condition]
statement
Computer Tyme * MarxMenu * Users Manual Page #65
-----------------------------------------------------------------
statement
ELSE
statement
statement
ENDIF
REPEAT->UNTIL Where, REPEAT
statement
statement
UNTIL [condition]
WHILE->ENDWHILE Where, WHILE [condition]
statement
statement
ENDWHILE
PROCEDURE->ENDPROC PROCEDURE (name)
statement
statement
ENDPROC
LOOP->ENDLOOP LOOP (number)
statement
statement
ENDLOOP
ENVIRONMENT VARIABLES USED BY MARXMENU
MarxMenu uses a variety of environment variables to control various
MarxMenu functions. Many of these variables are optional.
Set MouseX=(Number)
Sets the horizontal sensitivity of the mouse. Default is 15.
Set MouseY=(Number)
Sets the vertical sensitivity of the mouse. Default is 25.
Set MxEcho=(On/Off)
If you set the first line of MARX.BAT to @ECHO %MXECHO% then by setting
the environment variable MxEcho to ON or OFF, you can control the echo
in the MARX.BAT file without having to edit it. This allows you to do
diagnostics on a network without messing up other users.
Set Temp=(Directory)
Computer Tyme * MarxMenu * Users Manual Page #66
-----------------------------------------------------------------
Normally, MarxMenu creates temporary batch files in the same directory
as MARXMENU.EXE. If you set TEMP to a directory, MarxMenu will use this
directory instead. This complies with Windows / DOS 5.0 standards.
Set MxCmd=(Command)
MarxMenu uses MXCMD to control what the MARX.BAT file executes. You must
have enough environment space available for MarxMenu to use.
Set KSV=
MarxMenu stores a series of keystrokes in the KSV variable when
SavePosition is On.
Set STATION=(Number)
If you are on a network that is not Novell, then you should set this
variable to a unique number for each station between 0 and 255.
Set TASK=(Number)
If you are running a multi-tasking operating system other than DesqView,
and MarxMenu is running more than one task, then set an environment
variable TASK to a unique number for each task.
MarxMenu also accesses your COMSPEC variable and your PATH variable when
executing programs.
MARXMENU DATABASE FUNCTIONS
Well, after talking about it for years, MarxMenu now includes a strong
set of database tools. The database is based on Novell's Btrieve
interface. Thus it has the reliability of proven database technology. We
are pushing Btrieve to the limit and then some in order to get the
requirements needed from a database engine.
Btrieve is primarily a fixed length database engine with the ability to
add a single variable-length field on the end of a record. When using
MarxMenu with Btrieve, we typically store MarxMenu-style variables in
the variable-length section and reserve the fixed-length section for key
fields only. While we recommend you consider this approach you are free
to develop and use any data models you prefer.
You will notice several unusual things about MarxMenu as a database.
We decided that the square model or relationally-linked square model is
to limiting. You can do square model databases if you want to, but the
experience of getting rid of the square model is like an animal being
let out of a cage for the first time. It's a little scary at first.
Computer Tyme * MarxMenu * Users Manual Page #67
-----------------------------------------------------------------
When you create a MarxMenu Btrieve database you may define all your
fields, if you want, but you are only required to define the fields that
will be used as key fields. You will need to define the fields type, and
for key fields the key properties.
When data is written to a file the data is passed as a MarxMenu array.
The first elements of the array have to match the fixed portion of your
structure, normally your key fields. Any elements after the key fields
are written in MarxMenu format to the variable-length section of the
record. Thus, after the key fields you can do whatever you want. Here is a
list of some of the flexible features.
1) Records do not have to contain the same fields or the same number of
fields. You can have 20 fields in one record and 5 fields in the
next one. There are no rules that the data in one field of a record
has to be of the same data type as the same field of the previous
record.
2) Records can contain MarxMenu-style arrays. Thus if you are using a
phone field as an array of phone numbers you can store as many phone
numbers in that field as you want. MarxMenu can support arrays
within arrays of up to 30 levels within a single record.
3) Since MarxMenu supports writing MarxMenu-style variable structures
to database records, you need not have to specify the type of data,
the data size, or the structure of the data before you access the
file. If you want to write data you just do it.
Use of the Btreive commands require that you have Btrieve 5.10 or later.
You will need to have the Btrieve NLM running on the server and
BRREQUEST.EXE running on the workstation to use this database in
client-server mode, or BTRIEVE.EXE running on the workstation if you are
not running in client-server mode. All the Btreive database commands
start with the BTRV prefix.
To use BTRIEVE.EXE load it with the /E switch as follows:
BTRIEVE /E
Only network versions of MarxMenu contain the BTRV database commands,
the single user version is not equiped with this feature.
At the time of printing of this manual the Btrieve database commands are
new. For more details, new commands, and examples look in the
MARXREAD.ME file and the MarxHelp program.
Computer Tyme * MarxMenu * Users Manual Page #68
-----------------------------------------------------------------
ADDITIONAL INFORMATION
MarxMenu is a growing product with additional features and enhancements
being added all the time. Therefore, the manual will never be completely
current.
Whenever new features are added, the MARXREAD.ME file is updated to show
you the new additions since the manual was printed. These changes are
also added to the MarxHelp program so that the online help is always
kept current with the released software.
COMPUTER TYME ON COMPUSERVE
The Computer Tyme Section of the Novell Vendor Forum is your window to
the body of additional services available on Compuserve. Many services
complement specific applications. Others add a new dimension to business
endeavors. Still others cater to personal interests, from aviation to
Zinfandel wines. Some of these services include:
INVEST WISELY - Speed stock purchases and sales with convenient
electronic brokerage services. View stock trends online, research
investment possibilities, or transfer data from Compuserve for use in
your favorite spreadsheet package.
TAKE A TRIP - Compare airline schedules and fares on Compuserve. Find
the least expensive flight or best time to fly. Book your tickets
online, or pass information on to your travel agent.
DO YOUR HOMEWORK - Turn hours of research into minutes online, with
hundreds of national and international databases representing diverse
specializations. Avoid lengthy library searches by pulling up abstracts
and full articles directly online.
BE INFORMED - Turn to Compuserve's online news service for daily news
from the associated Press' national and international wires, United
Press International's national and regional wires, The Washington Post,
Reuters, and other reputable sources. The Executive News Service scans
these wires for articles on topics you select, then clips and saves them
for reading at your leisure.
DON'T PASS THIS UP - As a Computer Tyme customer, you're entitled to a
free Introductory Membership to Compuserve, including:
1) A FREE on month membership to access all of Compuserve's Basic
Services.
2) A $15 introductory usage credit to explore the Computer Tyme Section
of the Novell Vendor Forum and Compuserve's other Extended and Premium
Service offerings.
Computer Tyme * MarxMenu * Users Manual Page #69
-----------------------------------------------------------------
3) A complimentary subscription to Compuserve Magazine, Compuserve's
monthly computing magazine.
For those of you who are using Novell networks, the best place to get
Novell technical support is in the many forums that Novell provides on
Compuserve. In fact, it has been my experience that the support on
Compuserve is significantly better than what Novell provides directly.
If you are a serious Novell user, you definitely need to be on
Compuserve. That's where the real Novell support is.
To start connecting with Computer Tyme, Novell, and other Compuserve
members call 800-524-3388 and ask for representative #419. If you are
already a Compuserve member, enter GO COMPTYME at any ! prompt.
MARXMENU COMMANDS
MarxMenu contains a rich set of commands. They are listed here
alphabetically and by command category. You don't have to learn them all
so don't let the size of the list scare you.
In the following command list, words contained within ( ) are command
parameters that must be included after the menu command. The numeric
range for the <column> parameter is 1 - 80 decimal, and for the <row>
parameter the range is 1 - 25, 43, or 50 decimal depending on how many
lines your monitor displays.
| (Vertical Bar)
Forces MarxMenu interpretation under an OnKey Command. If not for the |
(Vertical Bar), the command under an OnKey would be written to a batch
file. The | is only used under OnKey commands.
Example:
OnKey 'S'
|password 'hello' 3 4
ECHO Type EXIT to return to menu
COMMAND.COM
OnKey 'X'
|if UpperCase(ReadEnv('USERNAME')) = 'SUPERVISOR'
SYSCON
|else
| SecurityBreach('You do not have access to this function!')
|endIf
Category: Misc
Computer Tyme * MarxMenu * Users Manual Page #70
-----------------------------------------------------------------
( : Operator
Starts logical interpreter grouping.
Used to force evaluation of an expression other than the normal left to
right order.
Example:
2 * 3 + 2 evaluates to 8
2 * ( 3 + 2 ) evaluates to 10
See Also: )
Category: Misc
) : Operator
Ends logical interpreter grouping.
See Also: (
Category: Misc
* : Operator
Multiplies two numbers.
Example:
4 * 6 ;returns 24
Category: Math Float
+ : Operator
Adds two numbers or two strings.
Example:
"Hello" + " " + "World" ;returns "Hello World"
2 + 2 ;returns 4
The plus operator can also used to concatinate arrays or concatinate
values to arrays.
Example:
X[1] = 1
X[2] = 2
Y[1] = 3
Y[2] = 4
Computer Tyme * MarxMenu * Users Manual Page #71
-----------------------------------------------------------------
Z = X + Y ;returns an array containing [1,2,3,4]
Z = X + "A" ;returns an array containing [1,2,'A']
Z = "A" + X ;returns an array containing ['A',1,2]
Category: Math String Float Array
- : Operator
Subtracts two numbers.
Example:
7 - 4 ;returns 3
Category: Math Float
/ : Operator
Divides two numbers.
Example:
6 / 3 ;returns 2
Category: Math Float
< : Operator
Less Than - Compares two numbers or strings.
Example:
3 < 4 = True
'AB' < 'CD' ;returns True
Category: Math String Float
<= : Operator
Less Than or Equal - Compares two numbers or strings.
Example:
3 <= 4 = True
'AB' <= 'CD' ;returns True
Category: Math String Float
Computer Tyme * MarxMenu * Users Manual Page #72
-----------------------------------------------------------------
<> : Operator
Not Equal - Compares two numbers or strings.
Example:
3 <> 4 = True
'AB' <> 'CD' ;returns True
Category: Math String Float
= : Operator
Equal - Compares two numbers or strings.
Example:
3 = 4 = False
'AB' - 'CD' ;returns False
Category: Math String Float
> : Operator
Greater Than - Compares two numbers or strings.
Example:
3 > 4 = False
'AB' > 'CD' ;returns False
Category: Math String Float
>= : Operator
Greater Than or Equal - Compares two numbers or strings.
Example:
3 >= 4 = False
'AB' >= 'CD' ;returns False
Category: Math String Float
Abs : Number
Returns the absolute value of a number. The absolute value is the value
of the number without the sign.
Example:
Abs(-6) ;returns 6
Computer Tyme * MarxMenu * Users Manual Page #73
-----------------------------------------------------------------
Category: Math Float
Actual
If you want to read or write to a variable directly that is referencing
another variable I have provided the command Actual. Actual overrides
any pointers set by the command Loc.
Example:
Dispose Actual B
Actual B = 5
See Also: Loc
Category: Variable
Alias
Alias (name) = (string)
This is a compiler level text substitution command. When (name) is
defined as (string) whenever you use (name) it is the same to the
compiler as if (string) were typed there.
Example:
Alias TwoPlusThree = "(2 + 3)"
.
.
.
2 * TwoPlusThree = 10
.
Writeln TwoPlusThree
Writeln TwoPlusThree is the same as Writeln (2 + 3)
Category: Misc
AllowAbort (On/Off)
MarxMenu was written to allow processes to be aborted and in a very
smooth way eliminating the need for the user to deal with complicated
error logic. In some cases this has gotten in the way of specific
control when the user presses the escape key or other error occurs.
If AllowAbort is set to Off, MarxMenu will continue on to the next
command. You can then test LastKey to see if the escape key was pressed.
If the user presses escape a nul string is returned.
See Also: AllowEsc
Computer Tyme * MarxMenu * Users Manual Page #74
-----------------------------------------------------------------
Category: Misc
AllowEsc (On/Off)
Several MarxMenu commands such as PickOne, PickMany and PickFile allow
you to press escape to abort. If you turn AllowEsc Off then the escape
key is ignored. This forces the user to make a choice.
See Also: AllowAbort
Category: Misc
And : Operator
Returns logical And if operators are boolean; or bitwise And if
operators are numeric.
Example:
if (Month = Dec) and (Day = 25) then Writeln 'Merry Christmas!'
7 and 3 = 3 ;0111 and 0011
Note: The parentheses are necessary because MarxMenu interprets from
right to left.
See Also: Or Xor Not
Category: Math Boolean
AnsiWindows (On,Off)
If AnsiWindow is set to On, MarxMenu interprets Ansi escape codes in a
window.
See Also : VT100mode
Category : Display, Modem
AppendArray (Array,Value)
AppendArray appends Value to the end of an array. The number of elements
is increased by one. It is not used to append two arrays "end to end".
Example:
var X
X[1] = 'TEST1'
AppendArray(X,'TEST2')
Loop X
Writeln X[LoopIndex]
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #75
-----------------------------------------------------------------
This Prints:
TEST1
TEST2
Category: Array
ApplicationMemory : Number
Returns the number of bytes of memory available to an application when
MarxMenu exits out to the MARX.BAT file. This is the actual amount of
RAM available to your application.
See Also: FreeMemory
Category: Memory
ArcTan (Radians) : Real
Returns the ArcTangent of a real.
Category: Math Float
ArrayInsert (Array,Position,Count)
ArrayInsert inserts space in Array at location Position for Count
locations.
Example:
var A
Loop 5
A[LoopIndex] = LoopIndex
EndLoop
ArrayInsert(A,3,1)
A[3] = 10
Array A will be [1 2 10 3 4 5]
Category: Array
AssignList (2D Array)
AssignList reads the network assign list table and return a 2
dimensional array containing the local names and the network names.
Example:
var X
AssignList (X)
Computer Tyme * MarxMenu * Users Manual Page #76
-----------------------------------------------------------------
Loop X
Writeln X[LoopIndex,1] '=' X[LoopIndex,2]
EndLoop
See Also: CancelListEntry MakeListEntry
Category: Novell MSNet Vines
BadDate : Boolean
Set to true if you try to convert a string to a date and the date is
invalid.
Example:
TimeOf('02-30-92') ;Sets BadDate to True
See Also: TimeOf
Category: Time
Bat (String)
Bat is used to write a line to the batch file the same way that lines
under OnKey commands do. All the same rules apply. The batch file is
created and executed when the menu exits. Thus if Bat commands are
intermixed with other MarxMenu commands the other MarxMenu command are
executed first. The Bat command actually only puts the command in a
buffer for later execution.
Bat statements give you more control over what MarxMenu executes and
allow you to include the contents of MarxMenu variables in your batch
files or use complex formulas to create batch file lines.
When using Bat under an OnKey statement, be sure to use the vertical bar
in front of it. Bat gives you more control over what is sent to the
batch file that MARX.BAT executes.
Example:
OnKey 'D'
CLS
|BAT "DIR " HomeDirectory '\' UserName
PAUSE
See Also: OnKey
Category: Execution
Computer Tyme * MarxMenu * Users Manual Page #77
-----------------------------------------------------------------
BatFileName : String
Returns the name of the batch file that MarxMenu would create if
MarxMenu were to create a batch file automatically.
Category: String
BigShadow
Selects big shadow type. This is the default shadow.
See Also: SmallShadow ShadowPosition ShadowColor
Category: Display
BinString (Number, Length) : String
BinString converts a number into a base 2 binary string. If Length > 0
then the number will have enough leading zeros to make it Length long.
If Length = 0 then leading zeros are removed. Length must be 32 or less.
Example:
Writeln BinString(45,8) ;returns 00101101
Writeln BinString(45,0) ;returns 101101
See Also: HexString
Category: String
BiosDate : String
Returns the date of the rom Bios.
Category: System
Blanked : Boolean
Returns true if the screen blanker has kicked it. This lets you alter
your idle program based on whether the screen blanker is active.
See Also: IdleProgram
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #78
-----------------------------------------------------------------
BlankMessage (String)
When the screen blanks out, this one line message is displayed. If
BlankMessage is not set, the date and time will be displayed.
Example:
BlankMessage = 'Out to Lunch!'
See Also: ConsolePos
Category: String
BlankScreenProgram : Procedure
This allows you to specify a custom procedure to have executed in place
of the MarxMenu internal screen blanker. It also overrides the
IdleProgram so if you are running something in your idle program that
you want to continue to run when the screen goes blank, call your idle
procedure from the screen blanker procedure.
If you exit your screen blanker and MarxMenu thinks the screen should
still be blank it will call it again. You can set UnBlank to True in
your screen blanking program to override this and unblank the screen.
When MarxMenu determines it's time to activate the screen blanker, it
first blanks the screen then calls the BlankScreenProgram. When MarxMenu
decides it's ready to unblank the screen it sets UnBlank to true. When
your BlankScreenProgram procedure is finished, MarxMenu will restore
your screen to it's original condition upon exit.
Commands like UseNovPassword, LockWord, and BlankTime will work with
your screen blanker.
To set up a blank screen program:
BlankScreenProgram = Loc Procedure
Example:
BlankScreenProgram = Loc RunWorm
To switch back to normal screen blanking run:
Dispose(ScreenBlankProgram)
For an example of a blank screen look at WORM.INC.
The BlankScreenProgram can be used to run an external program to blank
the screen. So if you have some slick fractal program that you like
MarxMenu will run it. Here's how you would set it up.
Computer Tyme * MarxMenu * Users Manual Page #79
-----------------------------------------------------------------
BlankScreenProgram = Loc BlankProg
Procedure BlankProg
Execute 'FRACTAL.EXE'
UnBlank = True
EndProc
See Also: IdleProgram UnBlank
Category: Display
BlankTime (Minutes)
Sets the number of minutes before the screen blanks out to prevent
screen burn. Since this is not a resident program, screen blanking is
only active while the menu system is active. Setting BlankTime to 0
prevents screen blanking.
Example:
BlankTime = 10 ;set to 10 minutes
BlankTime = 0 ;disables screen blanking
Writeln BlankTime " Minutes of inactivity will cause screen blanking."
Category: Display
Blink : Boolean
Blink is a boolean variable that when set to true allows you to specify
colors that will blink. To make a color that blinks, set the background
color to a bright color. A bright color is a color from 8 to 15.
Normally, when Blink is off, MarxMenu strips the high bit of the colors.
When Blink is on, high bit stripping is disabled.
Example:
Blink
TextColor Green LRed
Because the background color is light red, the text will blink.
Warning: Blinking characters can cause headaches and eye strain. I
resisted adding this feature for a long time because I personally hate
excessive blinking characters on the screen. I now recognize that
blinking can be very effective when used correctly. Please use blinking
sparingly.
Category: Color
Computer Tyme * MarxMenu * Users Manual Page #80
-----------------------------------------------------------------
BlockBox
Selects menu borders to have a block type edge.
See Also: SingleLineBox DoubleLineBox CustomBox NoBoxBorder
Example:
BoxBordercolor yellow black
BoxInsideColor White Black
BlockBox ;<- Set Border Type to Block Style
DrawBox 10 10 60 10
Category: Display
BootDrive : String
Returns the drive letter of the boot drive. This command only works with
DOS 4+, on all other versions of DOS it returns a null string. On
diskless workstations the BootDrive will be A.
Category: File
BoxBorderColor (Foreground,Background)
Sets colors for box border.
Example:
BoxBordercolor LRed black ;<- Set Border Colors to LRed/Black
BoxInsideColor White Black
BlockBox
DrawBox 10 10 60 10
Category: Color
BoxHeader (String)
There are three possible box header strings. This command sets the
center header message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxHeader ' Center BoxHeader String ' ;<- Sets the Box Header String
BoxBordercolor LRed Black
BoxInsideColor White Black
BlockBox
DrawBox 5,6,70,9
See Also: BoxHeaderLeft BoxHeaderRight
See Also: BoxFooter BoxFooterLeft BoxFooterRight
Computer Tyme * MarxMenu * Users Manual Page #81
-----------------------------------------------------------------
Category: Display
BoxHeaderColor (Foreground,Background)
There are three possible box header strings. This command sets colors
for all the box headers and box footers strings.
Example:
BoxHeader ' Center Box Header String '
BoxFooter ' Box Footer String '
BoxBordercolor LRed Black
BoxInsideColor White Black
BoxHeaderColor Yellow Black ;<-- Set Box Header/Footer Colors
DrawBox 5,6,70,9
Category: Color
BoxHeaderLeft (String)
There are three possible box header strings. This command sets the
left header message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxHeaderLeft ' Left Header String ' ;<- Set Left Header String
BoxBordercolor LRed Black
BoxInsideColor White Black
BoxHeaderColor Yellow Black
DrawBox 5,6,70,9
See Also: BoxHeader BoxHeaderRight
See Also: BoxFooter BoxFooterLeft BoxFooterRight
Category: Display
BoxHeaderRight (String)
There are three possible box header strings. This command sets the
right header message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxHeaderRight 'Right Header String ';<- Set Right Header String
BoxBordercolor LRed Black
BoxInsideColor White Black
BoxHeaderColor Yellow Black
DrawBox 5,6,70,9
Computer Tyme * MarxMenu * Users Manual Page #82
-----------------------------------------------------------------
See Also: BoxHeader BoxHeaderLeft
See Also: BoxFooter BoxFooterLeft BoxFooterRight
Category: Display
BoxFooter (String)
There are three possible box footer strings. This command sets the
center footer message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxHeader ' Center Box Header String '
BoxFooter ' Box Footer String ' ;<-- Set Center Footer String
BoxBordercolor LRed Black
BoxInsideColor White Black
BoxHeaderColor Ye9llow Black
DrawBox 5,6,70,9
See Also: BoxHeader BoxHeaderLeft BoxHeaderRight
See Also: BoxFooterLeft BoxFooterRight
Category: Display
BoxFooterLeft (String)
There are three possible box footer strings. This command sets the
Left Footer message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxFooter ' Center Footer String '
BoxFooterLeft ' Left Footer String ' ;<-- Set Left Footer String
BoxFooterRight ' Right Footer String '
BoxBordercolor LRed Black
BoxInsideColor White Black
BoxHeaderColor Yellow Black
DrawBox 5,6,70,9
See Also: BoxHeader BoxHeaderLeft BoxHeaderRight
See Also: BoxFooter BoxFooterRight
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #83
-----------------------------------------------------------------
BoxFooterRight (String)
There are three possible box footer strings. This command sets the
Right Footer message for the next box displayed. This command must be
used before the DrawBox command.
Example:
BoxFooter ' Center Footer String '
BoxFooterLeft ' Left Footer String '
BoxFooterRight ' Right Footer String ' ;<-- Set Right Footer String
BoxHeaderColor Yellow Black
BoxBordercolor LRed Black
BoxInsideColor White Black
DrawBox 5,6,70,9
See Also: BoxHeader BoxHeaderLeft BoxHeaderRight
See Also: BoxFooter BoxFooterLeft
Category: Display
BoxInsideColor (Foreground,Background)
This command sets the colors for the interior of a box.
Example:
BoxBordercolor LRed Black
BoxInsideColor White Black ;<- Set Inside Colors to White on Black
DrawBox 5,6,70,9
Category: Color
Break (On/Off)
Turns DOS break checking On and Off the same way that it does from
batch files.
Category: System
BrightBackground (On/Off)
This command switches between bright background modes and blink modes.
This doubles the number of colors that MarxMenu can produce.
This command affects the video controller directly. Thus, it may not
work on all computers especially if you are running something weird.
Once this is set in MarxMenu it stays set. So if you run another program
that has blink in it, it will use 16 background colors instead. The
solution is to set BrightBackground Off right before you run a program
that requires blinking.
Computer Tyme * MarxMenu * Users Manual Page #84
-----------------------------------------------------------------
Example:
OnKey 'X'
|BrightBackground Off
PROCOMM
Warning! This program uses a trick that may not be compatible with some
TSR programs. If you can get away with it, fine. But, if you have
problems where TSR's cause your screen to blink, then don't use this
command.
Category: Video
BtrvAbortTransaction
BtrvAbortTransaction is used to abort all changes to the file that have
occurred since the BtrvBeginTransaction was executed.
See Also: BtrvBeginTransaction BtrvEndTransaction
Category: Btrieve
BtrvBeginTransaction
Betrieve supports a concept called transaction tracking. With
transaction tracking you can use the BtrvBeginTransaction command to set
a file condition flag marking the start of a file process. Should the
file process be interrupted before the end of the process the files will
be restored to the original condition they were in prior to the
BtrvBeginTransaction.
Result Codes:
37 - Transaction is Active
See Also: BtrvAbortTransaction BtrvEndTransaction
Category: Btrieve
BtrvClearOwner (Handle)
BtrvClearOwner clears the owner and allows normal access to the file.
Example:
BtrvClearOwner (Handle)
See Also: BtrvSetOwner
Category: Btrieve
Computer Tyme * MarxMenu * Users Manual Page #85
-----------------------------------------------------------------
BtrvClose (Handle)
BtrvClose closes the file. The parameter `Handle' is the file handle
returned from BtrvOpen.
Example:
BtrvClose (Handle)
See Also: BtrvOpen
Category: Btrieve
BtrvCreate (FileName,Fields)
BtrvCreate is the most complicated Btrieve call. It defines the creation
of the Btrieve database. The fields parameter is a two dimensional
MarxMenu array that describes the fields in the file. It is designed to
support either standard Btrieve fixed-length fields or MarxMenu key
fields. Using MarxMenu fields is the easiest because you only have to
define the key fields. Non-key fields do not have to be predefined.
The easiest way to define these fields is to create a comma delimited
text file and use ReadAscTextFile('FIELDS.TXT',Fields). This will create
the array needed by BtrvCreate. The text file might look as follows:
Name,String,35,Key,DUP,MOD,UPPER,DEC
CustomerNumber,Auto,Key
From,String,35
Password,String,15
Access,Num
Flags,String,10
FirstDate,Date
LastDate,Date
Calls,Num
CallTime,Time
Phone,String,15
Example:
Var Fields, FieldHandle
ReadAscTextFile('FIELDS.TXT',Fields)
BtrvCreate('BBSUSER.BTD',Fields)
FileHandle = BtrvOpen('BBSUSER.BTD',Fields)
The above example creates a conventional fixed-length database with one
key field, the "name" field. Each line in the definition file defines a
new field. Each line has at least two parameters. The first parameter is
the field name. It is followed by the field type. There are five legal
field types. They are:
Computer Tyme * MarxMenu * Users Manual Page #86
-----------------------------------------------------------------
String - Contains alphanumeric strings. String fields have a required
third parameter, the maximum length of the string. In the
above example the "Name" and "From" fields both have max
lengths of 35 characters.
Num - Integer numeric fields. This field type supports storing
integer numbers.
Date - Dates fields. The DOS country code is automatically supported
to establish date format. If not specified, the default
format is "MM/DD/YY".
Time - Time fields. This command also reads the DOS country code to
establish the proper format. Otherwise default is "HH:MM:SS".
Auto - Auto increment field. This field is a numeric field that is
filled in by Btrieve. If you pass a zero value, Btrieve will
fill it in automatically with sequential unique numbers. The
first record being one, the second record being two, etc. If
records are deleted the numbers are not reused. If you pass a
non-zero value that does not match any other record, Btrieve
will accept that value. This feature can be used to provide
unique record numbers.
USING KEY FIELDS
Key fields are fields that are have internal lookup indexs automatically
defined and maintained by the Btrieve system. If you want to use the
indexed lookup `BtrvGet_____' series of commands then the field you
reference must be a key field. You define a key field by adding the
parameter "KEY" as the third parameter on the field definition line.
When specifying a field as a key field you have four optional
configuration parameters as seen in the previous example. They are:
DUP - {Duplicates} This permits the field to have duplicate values
in multiple records. If this parameter is not specified then no
two records may have the same value in the affected field. In
reality, you will almost always specify this parameter when
defining a key field.
MOD - {Modifiable} This allows existing existing field records to be
modified. If this parameter is not specified then once a record
is written, the affected field is set in stone and changes are
not permitted.
UPPER- {UpperCase Only} Used in cunjunction with string fields only,
this will force all text information to be sorted as UPPERCASE.
This feature requires Btrieve 6.0 or later.
Computer Tyme * MarxMenu * Users Manual Page #87
-----------------------------------------------------------------
DEC - {Descending Order} This caused the key stored in the affected
field to be maintained in reverse order.
USING MARXMENU STYLE DATABASE
If you wanted to use a MarxMenu-style database then only the first two
lines of the above example need be in the file. This would create a file
with two fixed-length key fields and put the rest of the fields in the
variable-length section. Using the MarxMenu style you can pass anything
you want for the rest of the fields.
Name,String,35,Key,DUP,MOD,UPPER,DEC
CustomerNumber,Auto,Key
--------------------------------------
|Name|CustomerNumber|All Other Fields|
--------------------------------------
^ ^ ^
| | |
Fixed Length --+----+ +--- Variable Length
In a MarxMenu-style database, you pass data to and from the file using
MarxMenu-style array variables. The first fields of the array must match
the key fields. But the rest of the fields can be anything you want.
They can be multidimensional arrays. The fields do not have to be the
same from one record to the next. Record number one can have five
fields, where record number two can have twenty. After the key fields
you can do anything you want.
Result Codes:
18 - Disk Full
Category: Btrieve
BtrvDelete (Handle)
BtrvDelete deletes a record from a data file at the location of the last
data read from the file.
Example:
BtrvGetEqual(DataVar,'MARC PERKEL',1,Handle)
BtrvDelete(Handle)
See Also: BtrvInsert
Category: Btrieve
Computer Tyme * MarxMenu * Users Manual Page #88
-----------------------------------------------------------------
BtrvEndTransaction
BtrvEndTransaction is used at the end of a transaction tracking process.
This command updates the files with all the data to be written. Refer to
the BtrvBeginTransaction command for additional information.
See Also: BtrvAbortTransaction BtrvBeginTransaction
Category: Btrieve
BtrvGetEqual (DataVar,Value,Key,Handle)
BtrvGetEqual goes to the previous record of the file based on the key
number that you pass and reads the record matching Value into DataVar.
The type of value passed has to match the type of data for which the key
is defined. If the key is a string then Value is a string. If BtrvResult
is zero, the data was found. If BtrvGetNext is called after this, the
next sequential record based on the key is read.
Example:
BtrvGetEqual(DataVar,'MARC PERKEL',1,Handle)
Result Codes:
4 - Key Value not Found
6 - Invalid Key Number
See Also: BtrvGetLess BtrvGetLessOrEqu BtrvGetGreater
See Also: BtrvGetGreaterOrEqu
Category: Btrieve
BtrvGetFirst (DataVar,Key,Handle)
BtrvGetFirst goes to the first record of the file based on the key
number that you pass and reads the record into DataVar. This allows you
to access that database in the sorted order of the key. DataVar is a
MarxMenu variable and the data read creates an array of the fields
stored on disk.
Example:
Var Fields, Handle, DataVar
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('BBSUSER.BTD',Fields)
BtrvGetFirst(DataVar,1,Handle)
while BrtvResult = 0
loop DataVar
Write DataVar[LoopIndex] ' '
endloop
Writeln
BtrvGetNext(DataVar,1,Handle)
EndWhile
Computer Tyme * MarxMenu * Users Manual Page #89
-----------------------------------------------------------------
This example dumps the contents of a file to the screen.
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetLast BtrvGetNext BtrvGetPrev
Category: Btrieve
BtrvGetGreater (DataVar,Value,Key,Handle)
BtrvGetGreater goes to the next larger record of the file based on the
key number that you pass and reads the record greater than Value into
DataVar. The type of Value passed has to match the type of data for
which the key is defined. If the key is a string then Value is a string.
If BtrvResult is zero, the data was found. If BtrvGetPrev is called
after this, the next sequential record based on the key is read.
Example:
BtrvGetLess(DataVar,'MARC PERKEL',1,Handle)
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetEqual BtrvGetLess BtrvGetLessOrEqu
See Also: BtrvGetGreaterOrEqu
Category: Btrieve
BtrvGetGreaterOrEqu (DataVar,Value,Key,Handle)
BtrvGetGreaterOrEqu goes to the next larger or equal record of the file
based on the key number that you pass and reads the record greater than
or equal to Value into DataVar. The type of Value passed has to match
the type of data for which the key is defined. If the key is a string
then Value is a string. If BtrvResult is zero, the data was found. If
BtrvGetPrev is called after this, the next sequential record based on
the key is read.
Example:
BtrvGetLessOrEqu(DataVar,'MARC PERKEL',1,Handle)
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetEqual BtrvGetLess BtrvGetLessOrEqu BtrvGetGreater
Category: Btrieve
Computer Tyme * MarxMenu * Users Manual Page #90
-----------------------------------------------------------------
BtrvGetLast (DataVar,Key,Handle)
BtrvGetLast goes to the last record of the file based on the key number
that you pass and reads the record into DataVar. This allows you to
access that database in the sorted order of the key. DataVar is a
MarxMenu variable and the data read creates an array of the fields
stored on disk.
Example:
Var Fields, Handle, DataVar
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('BBSUSER.BTD',Fields)
BtrvGetLast(DataVar,1,Handle)
while BrtvResult = 0
loop DataVar
Write DataVar[LoopIndex] ' '
endloop
Writeln
BtrvGetPrev(DataVar,1,Handle)
EndWhile
This example dumps the contents of a file to the screen backwards.
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetFirst BtrvGetNext BtrvGetPrev
Category: Btrieve
BtrvGetLess (DataVar,Value,Key,Handle)
BtrvGetLess goes to the next smaller record of the file based on the key
number that you pass and reads the record less than Value into DataVar.
The type of Value passed has to match the type of data for which the key
is defined. If the key is a string then Value is a string. If BtrvResult
is zero, the data was found. If BtrvGetPrev is called after this, the
next sequential record based on the key is read.
Example:
BtrvGetLess(DataVar,'MARC PERKEL',1,Handle)
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetEqual BtrvGetLessOrEqu BtrvGetGreater
See Also: BtrvGetGreaterOrEqu
Computer Tyme * MarxMenu * Users Manual Page #91
-----------------------------------------------------------------
Category: Btrieve
BtrvGetLessOrEqu (DataVar,Value,Key,Handle)
BtrvGetLessOrEqu goes to the next smaller or equal record of the file
based on the key number that you pass and reads the record less than or
equal to Value into DataVar. The type of Value passed has to match the
type of data for which the key is defined. If the key is a string then
Value is a string. If BtrvResult is zero, the data was found. If
BtrvGetPrev is called after this, the next sequential record based on
the key is read.
Example:
BtrvGetLessOrEqu(DataVar,'MARC PERKEL',1,Handle)
Result Codes:
6 - Invalid Key Number
See Also: BtrvGetEqual BtrvGetLess BtrvGetGreater BtrvGetGreaterOrEqu
Category: Btrieve
BtrvGetNext (DataVar,Key,Handle)
BtrvGetNext goes to the next record of the file based on the key number
that you pass and reads the record into DataVar. This allows you to
access that database in the sorted order of the key. DataVar is a
MarxMenu variable and the data read creates an array of the fields
stored on disk.
Result Codes:
6 - Invalid Key Number
7 - Different Key Number
9 - End of File
See Also: BtrvGetFirst BtrvGetLast BtrvGetPrev
Category: Btrieve
BtrvGetPrev (DataVar,Key,Handle)
BtrvGetPrev goes to the previous record of the file based on the key
number that you pass and reads the record into DataVar. This allows you
to access that database in the sorted order of the key. DataVar is a
MarxMenu variable and the data read creates an array of the fields
stored on disk.
Result Codes:
6 - Invalid Key Number
7 - Different Key Number
9 - End of File
Computer Tyme * MarxMenu * Users Manual Page #92
-----------------------------------------------------------------
See Also: BtrvGetFirst BtrvGetLast BtrvGetNext
Category: Btrieve
BtrvIndexes (Handle) : Number
BtrvIndexes returns the number of key fields in a file. You must open
the file and get a file handle first.
Example:
Writeln BtrvIndexes (Handle)
Category: Btrieve
BtrvInsert (DataVar,Handle)
BtrvInsert adds a new record to the data file. The data is passed in the
array DataVar. If key fields are used, or if you are using traditional
style fixed-length fields, then the first elements of the array must
match the data structure of the file you defined with BtrvCreate. All
elements of the array after these fields are written to the
variable-length part of the file. The variable-length part can contain
MarxMenu multi-dimensional data structures.
Example:
BtrvInsert(DataVar,Handle)
Result Codes:
5 - Duplicate Key
18 - Disk Full
See Also: BtrvDelete
Category: Btrieve
BtrvOpen (FileName,Fields) : Handle
BtrvOpen is used to open the file for access. Since Btrieve files do not
store a list of fields you have to pass the same data structure you did
when you created the file. If successful, BtrvOpen will return a file
handle. This handle will be referenced by all other commands that access
this file.
Example:
Var Fields, Handle
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('BBSUSER.BTD',Fields)
If BtrvResult<>0
WriteLn "Btrieve Error: " BtrvResult " While Opening File."
EndIf
Computer Tyme * MarxMenu * Users Manual Page #93
-----------------------------------------------------------------
Result Codes:
46 - Access Denied
85 - File Locked
86 - File Table Full
87 - Handle Table Full
See Also: BtrvClose BtrvCreate
Category: Btrieve
BtrvPageSize (Handle) : Number
BtrvPageSize returns the page size of in a file. You must open the file
and get a file handle first. The page size is the amount of disk space
allocated when a file is extended.
Example:
Writeln BtrvPageSize (Handle)
Category: Btrieve
BtrvRecLen (Handle) : Number
BtrvRecLen returns the size of the fixed length part of in a file. You
must open the file and get a file handle first.
Example:
Writeln BtrvRecLen (Handle)
Category: Btrieve
BtrvRecords (Handle) : Number
BtrvRecords returns the number of records in a file. You must open the
file and get a file handle first.
Example:
Var Fields, Handle
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('CLIENTS.BTR',Fields)
Writeln BtrvRecords (Handle) ;# of Records in CLIENTS.BTR
Category: Btrieve
Computer Tyme * MarxMenu * Users Manual Page #94
-----------------------------------------------------------------
BtrvReset
BtrvReset is used to clear all transactions and close all files. It's a
good idea to start your programs with this command to clear any locks
that might be left out there from other programs that might have
aborted.
Example:
var fields
btrvreset ;Start with a clean slate!
readasctextfile('db.txt',fields) ;Get field Definitions
btrvcreate('phone.mb',fields) ;Create Btrieve File
writeln btrvresult ;Check for ok
Category: Btrieve
BtrvResult : Number
BtrvResult returns the result code from the last Btrieve call. A zero is
considered a success.
Example:
Procedure BtrieveError
If BtrvResult <> 0
Writeln 'Btrieve Error #',BtrvResult
Writeln 'Exiting Program...'
ExitMenu
EndIf
EndProc
Result Codes:
4 - Key Value not Found
5 - Duplicate Key Value
6 - Invalid Key Number
7 - Different Key Number
9 - End of File
10 - Modifiable Key Value Error
11 - Invalid File Name
12 - File not Found
18 - Disk Full
20 - Btrieve not Loaded
28 - Record too Long
29 - Key too Long
30 - Not a Btrieve File
41 - Operation not Allowed
46 - File Access Denied
78 - Deadlock Detected
86 - File Table Full
87 - Handle Table Full
92 - Transaction Table Full
Computer Tyme * MarxMenu * Users Manual Page #95
-----------------------------------------------------------------
For other codes use BtrvResultMessage to display the error.
See Also: BtrvResultMessage
Category: Btrieve
BtrvResultMessage : String
BtrvResultMessage automatically returns a string containing an error
message based on the value BtrvResult.
Example:
Writeln BtrvResultMessage ;write Btreive Error Message
See Also: BtrvResult
Category: Btrieve
BtrvSetOwner (Owner,Mode,Handle)
BtrvSetOwner is really a set password function. It restricts access to
the file unless you pass the owners name by setting BtrvOwner. The mode
controls access and data encryption as follows:
0 : No Btreive access - File Not Encrypted
1 : Read Only access - File Not Encrypted
2 : No Btreive access - File Encrypted
3 : Read Only access - File Encrypted
Example:
BtrvSetOwner('NERD',3,Handle)
Result Codes:
50 - Owner Already Set
See Also: BtrvClearOwner
Category: Btrieve
BtrvStepFirst (DataVar,Handle)
BtrvStepFirst goes to the first physical record of the file and reads
the record into DataVar. DataVar is a MarxMenu variable and the data
read creates an array of the fields stored on disk.
Example:
Var Fields, Handle, DataVar
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('BBSUSER.BTD',Fields)
Computer Tyme * MarxMenu * Users Manual Page #96
-----------------------------------------------------------------
BtrvStepFirst(DataVar,Handle)
while BrtvResult = 0
loop DataVar
Write DataVar[LoopIndex] ' '
endloop
Writeln
BtrvStepNext(DataVar,Handle)
EndWhile
This example dumps the contents of a file to the screen.
See Also: BtrvStepLast BtrvStepNext BtrvStepPrev
Category: Btrieve
BtrvStepLast (DataVar,Handle)
BtrvStepLast goes to the last physical record of the file and reads the
record into DataVar. DataVar is a MarxMenu variable and the data read
creates an array of the fields stored on disk.
Example:
Var Fields, Handle, DataVar
ReadAscTextFile('FIELDS.TXT',Fields)
Handle = BtrvOpen('BBSUSER.BTD',Fields)
BtrvStepLast(DataVar,Handle)
while BrtvResult = 0
loop DataVar
Write DataVar[LoopIndex] ' '
endloop
Writeln
BtrvStepPrev(DataVar,Handle)
EndWhile
This example dumps the contents of a file to the screen backwards.
See Also: BtrvStepFirst BtrvStepNext BtrvStepPrev
Category: Btrieve
BtrvStepNext (DataVar,Handle)
BtrvStepNext goes to the next physical record of the file and reads the
record into DataVar. DataVar is a MarxMenu variable and the data read
creates an array of the fields stored on disk. This is normally used to
work through a file when the search field in not a key field.
Computer Tyme * MarxMenu * Users Manual Page #97
-----------------------------------------------------------------
Example:
var fields,temp,handle,vararray
readasctextfile('data.txt',fields)
handle=btrvopen('phone.mxb',fields)
while btrvresult=0
btrvstepnext(vararray,handle) ;<- Step to next file record
writeln vararray[1] " " vararray[2]
endwhile
btrvclose(handle)
Result Codes:
9 - End of File
See Also: BtrvStepFirst BtrvStepLast BtrvStepPrev
Category: Btrieve
BtrvStepPrev (DataVar,Handle)
BtrvStepPrev goes to the previous physical record of the file and reads
the record into the variable DataVar. DataVar is a MarxMenu variable and
the data read creates an array of the fields stored on disk.
Result Codes:
9 - End of File
See Also: BtrvStepFirst BtrvStepLast BtrvStepNext
Category: Btrieve
BtrvStop
BtrvStop is used to unload BTRIEVE.EXE or BREQUEST.EXE from memory. You
can load the requestor before running MarxMenu as a database and unload
the requestor when you are finished. This reclaims the memory the
requestor was using.
Category: Btrieve
BtrvUnusedPages (Handle) : Number
BtrvUnusedPages returns the number of unused pages in a file. You must
open the file and get a file handle first. Unused pages are created when
data is deleted from a file.
Example:
Writeln BtrvPageSize (Handle)
Computer Tyme * MarxMenu * Users Manual Page #98
-----------------------------------------------------------------
Category: Btrieve
BtrvUpdate (DataVar,Handle)
BtrvUpdate changes a record in the data file at the last location
accessed with any command that reads a record. The data is passed in the
array DataVar. If key fields are used, or if you are using traditional
style fixed-length fields, then the first elements of the array must
match the data structure of the file you defined with BtrvCreate. All
elements of the array after these fields are written to the
variable-length part of the file. The variable length part can contain
MarxMenu multi-dimensional data structures.
Example:
BtrvGetEqual(DataVar,'MARC PERKEL',1,Handle)
if BtrvResult = 0
DataVar[3] = 37
BtrvUpdate(DataVar,Handle)
endif
Result Codes:
5 - Duplicate Key
7 - Different Key
10 - Modifiable Key Value Error
80 - Conflict
Category: Btrieve
BtrvVersion : Number
BtrvVersion returns a number representing the version number of Btrieve
that you are using. A zero indicates that Btrieve is not installed. If
Btrieve is installed then it returns 100 times the version number plus
the minor version number. Version 6.0 becomes 600. Version 5.10 becomes
510.
Example:
if BtrieveVersion = 0
Writeln "Sorry, but Btrieve must be loaded first!"
else
Writeln "You are running Btrieve Version #: " BtrvVersion
endif
Category: Btrieve
Computer Tyme * MarxMenu * Users Manual Page #99
-----------------------------------------------------------------
BuildPath (Array)
The command BuildPath will build a PATH environment variable based upon
the contents of a specified Array variable. The first element in the
array becomes the first search path.
Example:
Var PathList
Pathlist[1] = 'F:\PUBLIC'
Pathlist[2] = 'F:\DOS'
Pathlist[3] = 'F:\UTIL'
BuildPath (PathList) ;sets PATH=F:\PUBLIC;F:\DOS;F:\UTIL
See Also: SplitPath FixPath
Category: String Array Environment
CancelListEntry (Local Name)
This will take an entry out of the network redirection list for either a
print redirection or disk drive redirection.
Example:
CancelListEntry 'P:' ;cancels network drive mapping
CancelListEntry 'LPT1' ;cancels printer redirection
See Also: AssignList MakeListEntry
Category: Novell MSNet Vines
CapFirstChar (On/Off)
When CapFirstChar is set to On the first character and all characters
following a space are automatically capitalized during a Readln command.
See Also: Readln
Category: String
CapsColor (Foreground,Background)
Setting CapsColor allows capital letters and numbers to be a different
color than the rest of the text. This is used with the UseArrows command
to show which character is the one that selects the options in the
window. CapsColor is reset after any TextColor command, so be sure to
use CapsColor AFTER TextColor commands.
For this option the numbers 0 - 9 and some punctuation characters are
considered capitals.
Computer Tyme * MarxMenu * Users Manual Page #100
-----------------------------------------------------------------
Example:
CapsColor White Blue
See Also: DrawBox
Category: Color
CapsLock : Boolean
This variable can be used to read the status of the KeyBoard Caps Lock
indicator and to set the current caps lock mode.
Example:
if CapsLock then Write 'CapsLock is On'
CapsLock On ;Turns CapsLock On
CapsLock Off ;Turns CapsLock Off
CapsLock ; (by itself) turns CapsLock On.
if CapsLock
;do something
endif
See Also: ScrollLock NumLock
Category: System
Chain (MenuName)
This command will load a new menu. Unlike Jump, MarxMenu stays in
memory. The screen is not cleared. If the new menu has exactly the same
global variables, the contents of all global variables is retained.
Chain allows for a very quick transfer from one menu to another.
Example:
OnKey 'P'
|Chain ('USER') ;Chains to USER.MNU
Category: Execution
Char (Number) : String
Converts a number into a one character string.
Example:
Write (Char(65)) ;This will display 'A'
Computer Tyme * MarxMenu * Users Manual Page #101
-----------------------------------------------------------------
See Also: Ord
Category: String
ChDir (String)
Changes directories. The variable FileResult can be tested to see if it
was successful. ChDir can also be used to change drives.
Example:
ChDir( 'C:\HOME\MARXMENU' )
ChDir( 'B:' ) ; Will make drive B: the current drive
Category: Directory
CleanFileName (String) : String
Returns the full path name or directory name of a string. It also
removes occurrences of a '\\' in the string if they aren't at the
beginning of the string.
Thus the command:
CleanFileName('a:\\main.mnu') returns 'A:\MAIN.MNU'.
CleanFileName also removes extra ending '\' and capitalizes the path.
See Also: TrueName
Category: String
ClearKbdBuffer
ClearKbdBuffer clears the characters out of the keyboard buffer.
Category: Keyboard
ClearKeyEvents
ClearKeyEvents wipes out all key events for the current window. Since
child window inherit the key events of it's parent window, this command
allows you to wipe out these events when you want to open a new window
for another purpose where the existing key events wouldn't be
appropiate. This command only affects the current window.
Example:
DrawBox 2 2 78 20
ClearKeyEvents
ViewTextFile 'HELP.TXT'
Computer Tyme * MarxMenu * Users Manual Page #102
-----------------------------------------------------------------
See Also: KeyEvent
Category: Event
ClearLine (Char)
Clears the current line in the current window. The optional parameter is
for the decimal number of the IBM graphics character. If (Char) is
present, the line will be filled with the character.
Examples:
ClearLine ;Clears screen with blanks
ClearLine 205 ;Clears screen with char 205
Category: Display Ansi
ClearScreen (Char)
Clears the screen. The optional parameter is the decimal number
equivalent for an IBM graphics character. If (Char) is present, the
screen will be filled with (Char).
Examples:
ClearScreen ;Clears screen with blanks
ClearScreen 177 ;Clears screen with char 177
Category: Display Ansi
ClearScreenFirst (On/Off)
Used in conjunction with Execute. If on, will clear the screen before
running the program.
Example:
OnKey 'D'
|ClearScreenFirst On
|Execute 'C:\DM.COM'
The default is ON.
See Also: Execute
Category: Execution
Computer Tyme * MarxMenu * Users Manual Page #103
-----------------------------------------------------------------
ClearScreenOnExit (On/Off)
Controls whether or not the screen is cleared on menu exit. Default on.
See Also: Execute
Category: Display
ClockColor (Foreground,Background)
Sets colors for the on screen clock.
Example:
ClockColor Yellow Brown
Category: Color
ClockMode
ClockMode is a variable whose bits control the format of the on screen
clock when it is used.
ClockMode Bits:
---------------
0 24 hour mode
1 AmPm On
2 Show Seconds
3 UpperCase
4 3 char month
5 3 char Day of Week
6 Show Day of Week
7 Dash = 0 Slash = 1 MM-DD-YY or MM/DD/YY
8 Long Date
Bit 0 on sets hours display to 24 hour mode.
Bit 1 turns on the Am/Pm display.
Bit 2 on controls if time is shown as HH:MM:SS or just HH:MM.
Bit 3 shows date in only upper case.
Bit 4 on shows month in 3 characters.
Bit 5 shows Day of week as 3 characters.
Bit 6 controls if Day of week is displayed.
Bit 7 controls if date is shown as MM-DD-YY or MM/DD/YY.
Bit 8 shows date in text. (October 3, 1990).
The default ClockMode is 326.
Example:
ClockMode 120
ClockColor White Red
ClockPos 1,1
Computer Tyme * MarxMenu * Users Manual Page #104
-----------------------------------------------------------------
Category: Display
ClockPos (Column,Row)
Puts a clock on the screen at location (column,row). The command
ClockPos 0 0 turns the clock off.
Example:
ClockPos 7 2
Category: Display
ClosePrinter
In MarxMenu the printer is just another text file. Closing the printer
is not required for ordinary printing. If you are changing printers you
need to run ClosePrinter before changing the printer name. The printer
is automatically opened by MarxMenu anytime you print anything.
If you are running Windows or DesqView, closing the printer allows other
programs to access the printer. So if you are running under any
multitasking shell, be sure to close the printer when you are done with
it.
If you are using a network like Novell, ClosePrinter will end the print
job and send it to the print queue. This avoids the need to wait for
print capture timeouts to take effect.
Closing the printer is good programming practice and will help you stay
out of trouble. It's like what your mother taught you. "When you're done
with something, put it away."
See Also: OpenPrinter PrinterName
Category: Printer
ClusterSize (Drive) : Number
Returns cluster size in bytes.
Example:
Writeln (ClusterSize 'C')
ClusterSize only looks at the first character of the string for the
drive letter.
Example:
ClusterSize (Path) ;returns clustersize of current drive.
Computer Tyme * MarxMenu * Users Manual Page #105
-----------------------------------------------------------------
Category: System
CmdLine : String
A System string variable that returns the rest of the command line after
the menu name. If you execute MARXMENU GOFILE *.BAT the CmdLine command
would return "*.BAT".
Example:
writeln cmdline ;returns the command line after the menu name.
Category: String
CMOS (Number) : Number
CMOS allows reads from and write to the CMOS RAM on the clock chip.
Example:
Writeln CMOS(16)
CMOS(16) = $42
Category: System
ColdBoot
Causes a cold reboot of the computer. This differs from a warm boot in
that it is a complete system reset that forces the computer to go
through the (POST, Power On Self Test) process. A warm boot does not
force a complete reset.
See Also: Reboot
Category: Execution
ColorScreen : Boolean
Returns true if screen is a color screen and in a color mode. Note:
Running MODE BW80 will cause ColorScreen to return false.
Example:
If ColorScreen
;Color
TextColor( White, Blue )
Else
;Monochrome
TextColor( White, Black )
EndIf
Computer Tyme * MarxMenu * Users Manual Page #106
-----------------------------------------------------------------
Category: Video
ComBaud : Number
Reads or sets the baud rate of the serial port indicated by the ComPort
command. Range from 110 to 115,000 baud.
Example:
ComBaud = 9600
Writeln ComBaud
See Also: ComDataBits ComStopBits ComParity
Category: Modem
ComBlockErrors : Number
During an upload or download ComBlockErrors returns the number of
errors that occurred during the current block.
See Also: ComXmitStatusProgram
Category: Modem
ComBlockNumber : Number
During an upload or download ComBlockNumber returns the current block
number.
See Also: ComXmitStatusProgram
Category: Modem
ComBlockSize : Number
During an upload or download ComBlockSize returns the number of bytes in
the block that's being transferred.
See Also: ComXmitStatusProgram
Category: Modem
ComBreakReceived : Boolean
Returns True if a break signal has been received at the serial port.
Example:
if ComBreakReceived then Writeln 'Break Received'
Computer Tyme * MarxMenu * Users Manual Page #107
-----------------------------------------------------------------
See Also: ComSendBreak
Category: Modem
ComBytesRemaining : Number
During an upload or download ComBytesRemaining returns the number of
bytes that is yet to be transferred.
See Also: ComXmitStatusProgram
Category: Modem
ComBytesTransferred : Number
During an upload or download ComBytesTransferred returns the number of
bytes that has been transferred.
See Also: ComXmitStatusProgram
Category: Modem
ComCD : Boolean
Returns the status of the carrier detect line on serial port indicated
by the ComPort Command.
Example:
if ComCD=True then Writeln 'Carrier Detected'
if ComCD then Writeln 'Carrier Detected'
Category: Modem
ComCDAbort : Boolean
ComCDAbort is set to True if ComWatchCD is on and the carrier is lost.
This is used as a signal to indicate that the modem has lost connection
and the host program should reset and prepare for the next call.
See Also: ComWatchCD
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #108
-----------------------------------------------------------------
ComCharReady : Boolean
Tests to see if a character has been received in the input buffer.
Example:
if ComCharReady then Ch = ComReadChar
See Also: ComReadChar
Category: Modem
ComDataBits : Number
Reads or sets the number of data bits. Range 5 - 8 bits.
Example:
ComDataBits = 8
Writeln ComDataBits
See Also: ComBaud ComStopBits ComParity
Category: Modem
ComDone
Uninitializes the port. Deallocates memory used by ComInitPort and
restores interrupt vectors.
See Also: ComInitPort
Category: Modem
ComDrainSendBuffer
ComDrainSendBuffer waits until all the characters in the send buffer go
to the modem. This allows the other end to get the last of the goodbye
message without being cut off by a hangup. With buffered modems you
should wait a few seconds after this command before hanging up the modem
to ensure that all the data has been transferred.
Category: Modem
ComDTR (On/Off)
Turns DTR (Data Terminal Ready) On or Off. Setting DTR to Off can be
used to hang up a modem.
Example:
ComDTR Off
Computer Tyme * MarxMenu * Users Manual Page #109
-----------------------------------------------------------------
Category: Modem
ComEchoRecChar : Boolean
When ComEchoRecChar is set to true then characters received are echoed
back to the sender. This option is useful when writing a host
communication program. The echoed character is intelligently processed.
See Also: ComReadChar
Category: Modem
ComEchoSendChar : Boolean
When ComEchoSendChar is set to true then characters sent are echoed
to the local screen. This option is useful when writing a host
communication program. The echoed character is intelligently processed.
When set to true, the following commands will also be processed for
correct com port output: TextColor, GotoXY, ClearScreen, ClearLine.
See Also: ComReadChar ComEchoRecChar
Category: Modem
ComEmptyRecBuffer
ComEmptyRecBuffer trashes the data in the receive buffer. This allows
you to get rid of incoming trash data.
See Also: ComEmptySendBuffer
Category: Modem
ComEmptySendBuffer
ComEmptySendBuffer trashes all the data in the send buffer that hasn't
been transferred. This allows you to create a hot key effect and makes
host programs act more responsive.
See Also: ComEmptyRecBuffer
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #110
-----------------------------------------------------------------
ComErrorLimit : Number
ComErrorLimit is the maximum number of errors that a file transfer can
have before an automatic transfer abort occurs. If set to 0 then it will
keep trying forever. The default limit is 100.
Category: Modem
ComFileName : String
During an upload or download ComFileName returns the name of the file
being transferred.
See Also: ComXmitStatusProgram
Category: Modem
ComFileSize : Number
During an upload or download ComFileSize returns the size of the file
being transferred.
See Also: ComXmitStatusProgram
Category: Modem
ComInitPort (Baud,DataBits,Parity,StopBits)
Initializes the ComPort. After selecting which com port you want to
initialize with the ComPort command, this must be run before other com
commands are executed.
Example:
ComPort = Com1
ComInitPort(38400,8,'N',1)
See Also: ComDone
Category: Modem
ComLastChar : String
ComLastChar returns the last character that was received with
ComReadChar.
See Also: ComReadChar ComCharReady ComReadTimeout ComReadln
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #111
-----------------------------------------------------------------
ComLastLine : String
ComLastLine returns the last line that was received that is not a blank
line. BackSpace characters are handled correctly.
Category: Modem
ComNewLineProgram : Procedure
ComNewLineProgram is a procedure variable that if set to point to a
procedure is executed every time a new line is received at the modem.
Example:
ComNewLineProgram = Loc ExamineLastLine
Procedure ExamineLastLine
var St P
P = pos('Time Sync:',ComLastLine)
if P = 0 then Return
St = mid(ComLastLine,P + 11,17) ;read Date and Time
NovServerTime = TimeOf(St)
EndProc
In this example, ExamineLastLine is executed once each new line and is
scaned for the word "Time Sync:". If the word is found it sets the
server time to the value following that word.
Category: Modem
ComParity : String
Reads or sets the parity.
N - None
E - Even
O - Odd
M - Mark
S - Space
Example:
ComParity = 'E'
Writeln ComParity
See Also: ComBaud ComDataBits ComStopBits
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #112
-----------------------------------------------------------------
ComPort : Number
Sets or reads the port that communication commands will effect. The
ComPost command must be executed first before any of the other
communication parameters can be set.
Example:
ComPort = Com1
Writeln ComPort
Category: Modem
ComProtocol : String
During an upload or download ComProtocol returns the name of the
transfer protocol being used.
See Also: ComXmitStatusProgram
Category: Modem
ComReadChar : String
Reads one character from the com port or input buffer. It will wait up
to ComReadTimeout ticks for the character. If no character is received
then ComTimeOut is set to True. If the ComStripHighBit command it set
then this command will automatically remove the high-order bit when
reading a character.
Example:
var Ch
Ch = ComReadChar
See Also: ComCharReady ComReadTimeout ComReadln
Category: Modem
ComReadln : String
Reads a line from the com port or input buffer. It will wait up to
ComReadTimeout ticks for the character. If no character is received then
ComTimeOut is set to True.
Example:
if ComReadln = 'OK' then
See Also: ComReadChar ComCharReady ComReadTimeout
Computer Tyme * MarxMenu * Users Manual Page #113
-----------------------------------------------------------------
Category: Modem
ComReadTimeout : Number
This variable controls the number of timer ticks (18.2 ticks per second)
that a read command will wait to receive data.
Example:
ComReadTimeout = 36 ;2 seconds
Category: Modem
ComRec1kXmodem (FileName)
Receive a file using the 1k-Xmodem (XModem1k) transfer protocol.
Example:
ComRec1kXmodem 'MXMENU.ZIP'
See Also: ComSend1kXmodem
Category: Modem
ComRecKermit
Receive a file, or group of files, using the Kermit transfer protocol.
Example:
ComRecKermit
See Also: ComSendKermit
Category: Modem
ComRecXmodem (FileName)
Receive a file using the Xmodem transfer protocol. There are two
versions of Xmodem (Checksum and CRC), the ComRecXmodem command is
compatible with both versions.
Example:
ComRecXmodem 'MXMENU.ZIP'
See Also: ComSendXmodem
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #114
-----------------------------------------------------------------
ComRecYmodem
Receive a file, or group of files, using the Ymodem transfer protocol.
Example:
ComRecYmodem
See Also: ComSendYmodem
Category: Modem
ComRecYmodemG
Receive a file, or group of files, using the YmodemG transfer protocol.
This protocol does not do any error checking and is therefore only
advisable for use with Error correcting modems.
Example:
ComRecYmodemG
See Also: ComSendYmodemG
Category: Modem
ComRecZmodem
Receive a file, or group of files, using the Zmodem transfer protocol.
Example:
ComRecZmodem
See Also: ComSendZmodem
Category: Modem
ComResult : Number
ComResult is a variable like FileResult that returns the success status
of com port activity. A result code or zero generally indicates success.
Example:
ComRecXmodem
if ComResult <> 0 then Writeln 'Xfer Not Successful!'
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #115
-----------------------------------------------------------------
ComRI : Boolean
Returns the status of the ring indicator line on serial ports.
Example:
if ComRI then Writeln 'Ringing'
Category: Modem
ComRTS (On/Off)
Activates and deactivates RTS/CTS handshaking.
Example:
ComRTS On
Category: Modem
ComSendBreak
Sends a break signal out the modem.
See Also: ComBreakReceived
Category: Modem
ComSend1kXmodem (FileName)
Send a file using the 1k-Xmodem (Xmodem1k) transfer protocol.
Example:
ComSend1kXmodem 'MXMENU.ZIP'
See Also: ComRec1kXmodem
Category: Modem
ComSendKermit (FileName or Array)
Send a file, or group of files, using the Kermit transfer protocol. If
you pass a filename it sends the file. If you pass an arrayname then
send all the files in the array list.
Example:
ComSendKermit 'MXMENU.ZIP' ;Send MXMENU.ZIP via Kermit
Example:
Var FileList
AppendArray(FileList,'FILE1')
AppendArray(FileList,'FILE2')
ComSendKermit FileList ;Send FILE1 & FILE2 via kermit
Computer Tyme * MarxMenu * Users Manual Page #116
-----------------------------------------------------------------
See Also: ComRecKermit
Category: Modem
ComSendXmodem (FileName)
Send a file using the Xmodem transfer protocol. There are two versions
of Xmodem (Checksum and CRC), the ComRecXmodem command is compatible
with both versions.
Example:
ComSendXmodem 'MXMENU.ZIP'
See Also: ComRecXmodem
Category: Modem
ComSendYmodem (FileName or Array)
Send a file, or a group of files, using the Ymodem transfer protocol. If
you pass a file name then it sends the file. If you pass it an array
then it will send all the files in the array list.
Example:
ComSendYmodem 'MXMENU.ZIP'
Example:
Var FileList
AppendArray(FileList,'FILE1')
AppendArray(FileList,'FILE2')
ComSendYmodem FileList
See Also: ComRecYmodem
Category: Modem
ComSendYmodemG (FileName or Array)
Send a file, or group of files, using the YmodemG transfer protocol. If
you pass a file name then it sends that file. If you pass an array then
it will send all the files in the array list. This protocol does not do
any error checking and is therefore only advisable for use with Error
correcting modems.
Example:
ComSendYmodemG 'MXMENU.ZIP'
Example:
Var FileList
AppendArray(FileList,'FILE1')
AppendArray(FileList,'FILE2')
ComSendYmodemG FileList
Computer Tyme * MarxMenu * Users Manual Page #117
-----------------------------------------------------------------
See Also: ComRecYmodemG
Category: Modem
ComSendZmodem (FileName or Array)
Send a file, or group of files, using the Zmodem protocol. If you pass a
file name then it sends that file. If you pass an array then it will
send all the files in that array list.
Example:
ComSendZmodem 'MXMENU.ZIP'
Example:
Var FileList
AppendArray(FileList,'FILE1')
AppendArray(FileList,'FILE2')
ComSendZmodem FileList
See Also: ComRecZmodem
Category: Modem
ComStopBits : Number
Reads or sets the number of stop bits. Range 1 - 2 bits.
Example:
ComStopBits = 1
Writeln ComStopBits
See Also: ComBaud ComDataBits ComParity
Category: Modem
ComStripHighBit (On/Off)
This command when set to on (true), will automatically remove the
high-order bit when using the ComReadChar command. File transfers and
the ComReadLn command are unaffected by this command.
See Also: ComReadChar
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #118
-----------------------------------------------------------------
ComThisLine : String
ComThisLine returns a string of characters that has been received from
the com port since the last CR. This can be used to see what prompts are
being received for automatic script processing.
Example:
if pos('Password',ComThisLine) > 0
ComWriteln 'Beast'
endif
Category: Modem
ComTimeout : Boolean
ComTimeout is set to True if the last command ended in a timeout error.
Example:
if ComTimeout then Writeln 'Something is stuck!'
Category: Modem
ComTotalErrors : Number
During an upload or download ComTotalErrors returns the number of
errors that occurred during the current file transfer.
See Also: ComXmitStatusProgram
Category: Modem
ComUseInt14
ComUseInt14 sets MarxMenu to talk to the ports through the Int14 serial
port routines. This can be used for network modem sharing applications
or if for some reason you don't want to talk to the UART directly. The
default Int14 routines are unbuffered.
Because of the limitations of the Int14 routines many of the more
advance MarxMenu communications commands do nothing when this option is
activated.
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #119
-----------------------------------------------------------------
ComUseUart
ComUseUart sets MarxMenu to talk to the UART directly. This is the
default mode. This command can be used to switch back if you used the
ComUseInt14 command.
Category: Modem
ComWatchCD : Boolean
When ComWatchCD is set to true MarxMenu watches the carrier detect
signal. If carrier detect is lost then several things happen. ComCDAbort
is set to true. ComEchoSendChar and ComEchoRecChar are set to false.
ComWrite and ComWriteln are disabled. ComCharReady is always true and
ComReadChar returns a char 0 when read.
This function is there to reset a host program without having to build
in a lot of error checking into the MarxMenu script. Setting ComWatchCD
to false resets everything and allows you to prepare for the next call.
Only set ComWatchCD to true after you receive a carrier detect signal.
It is also recommended that you insert a half second delay after
receiving a connect to deal with slow modems in fast computers.
Category: Modem
ComWrite (String)
Writes a string to the com port with no CR.
Example:
ComWrite '+++'
See Also: ComWriteln ComWriteTimeout
Category: Modem
ComWriteln (String)
Writes a string to the com port with CR.
Example:
ComWriteln 'ATDT 1-417-866-1665'
See Also: ComWrite ComWriteTimeout
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #120
-----------------------------------------------------------------
ComWriteTimeout : Number
This variable controls the number of timer ticks (18.2 ticks per second)
that a write command will wait to send data.
Example:
ComWriteTimeout = 36 ;2 seconds
Category: Modem
ComXmitAbortProgram
ComXmitAbortProgram is called while uploads and downloads are in
progress. If this is set to a MarxMenu procedure then you can write your
own control routine to control protocol abort. Your program needs to
return either a true to abort or a false to not abort.
Example:
ComXmitAbortProgram = loc XmitAbort
Procedure XmitAbort
if not KbdReady then Return False
Return ReadKey = Esc
EndProc
See Also: ComXmitStatusProgram
Category: Modem
ComXmitEnding : Boolean
This variable is set to true to indicate the ending for an upload or
download. It is used to end a communications status window.
See Also: ComXmitStatusProgram ComXmitStarting
Category: Modem
ComXmitStarting : Boolean
This variable is set to True to indicate the beginning for an upload or
download. It is used to start a communications status window.
See Also: ComXmitStatusProgram ComXmitEnding
Category: Modem
Computer Tyme * MarxMenu * Users Manual Page #121
-----------------------------------------------------------------
ComXmitStatusProgram
ComXmitStatusProgram is called while uploads and downloads are in
progress. If this is set to a MarxMenu procedure then you can write your
own status display routine to show progress status.
See Also: ComXmitAbortProgram
Category: Modem
Comment
Starts a Comment Block. All text is ignored until EndComment is
encountered.
Example:
Comment
=======================================
Everything between Comment and EndComment is ignored.
=======================================
EndComment
See Also: EndComment
Category: Misc
Console (On/Off)
MarxMenu has an built-in system control console that the user can
activate by pressing the Tab key. This allows them to dynamically set
the screen blanker parameters. The command "CONSOLE OFF" will disable
the Tab key function to prevent access console control box.
Category: Display
ConsoleBorderColor (Color,Color)
Sets the color of the console border.
See Also: ConsolePos
Category: Color
Computer Tyme * MarxMenu * Users Manual Page #122
-----------------------------------------------------------------
ConsoleHeaderColor (Color,Color)
Sets the color of the console header.
See Also: ConsolePos
Category: Color
ConsoleInsideColor (Color,Color)
Sets the color of the console inside.
See Also: ConsolePos
Category: Color
ConsolePos (Column,Row)
Sets the coordinates of the pop-up console menu.
Example:
ConsoleBorderColor( White,Blue )
ConsoleHeaderColor( Yellow,Blue )
ConsoleInsideColor( Yellow,Blue )
ConsolePos( 5,5 ) ; Column 5, Row 5
Category: Display
Const
Creates a constant.
Example:
Const
X = 50
St = 'MARXMENU'
Flag = True
See Also: Var Shared Qualifier
Category Variable
Cos (Radians) : Real
Returns the Cosine of a real.
Category: Math Float
Computer Tyme * MarxMenu * Users Manual Page #123
-----------------------------------------------------------------
CountryCode : Number
Returns the international country code from DOS. The country code is the
same number as the international telephone dialing code prefix.
Category: International
CpuClass : Number
Reads the type of CPU you are using and returns a number.
1 - 8088, 8086, 80186, V20, V30
2 - 80286
3 - 80386
4 - 80486
Example:
var Temp
Temp = CPUClass ;<- Read CPu Type into Var Temp
if Temp = 1
Writeln "This System is an XT Class Machine!"
elseif Temp = 2
Writeln "This System is an AT Class Machine!"
elseif Temp = 3
Writeln "That 386 is a powerful machine."
else
Writeln "Do you really rate having a 486?"
endif
See Also: CpuName McpClass
Category: System
CpuName : String
Returns the name of the CPU. CPU names include:
8088, 8086, V20 ,V30, 80188, 80186, 80286,
80386, 80386SX, 80486, 80486SX
See Also: CpuClass McpName
Category: System
Computer Tyme * MarxMenu * Users Manual Page #124
-----------------------------------------------------------------
CurrencySymbol : String
Returns the currency symbol based on the country code.
Category: International
CurrentDirectory : String
Returns the current directory.
Example:
Writeln CurrentDirectory
Category: String
CurrentEnvironment
CurrentEnvironment selects the current environment for use with
environment access commands.
See Also: ReadEnv SetEnv ReadEnvironment ShellEnvironment
See Also: ParentEnvironment MasterEnvironment
Category: Environment
CurrentWindow : Number
Returns the number of the current window. All windows are given a unique
number.
Example:
ThisWindow = CurrentWindow
See Also: SetTopWindow
Category: Display
Cursor (On/Off)
MarxMenu automatically turns the cursor on for certain kinds of input.
Using Cursor Off prevents MarxMenu from turning the cursor on. Cursor On
reverses this and allows MarxMenu to turn the cursor on when needed.
Example:
Cursor Off
Category: Video
Computer Tyme * MarxMenu * Users Manual Page #125
-----------------------------------------------------------------
CustomBox (String)
Selects a Box border using an 8-character string to define the sides
and the corners.
Example:
CustomBox ('12345678') ;This will help you figure out what
;position matches which side.
See Also: SingleLineBox DoubleLineBox BlockBox NoBoxBorder
Category: Display
DateSeparator : String
Returns the date separator character from the country information.
See Also: TimeSeparator DecimalSeparator CountryCode
Category: International Time
DateString (Time) : String
Returns the date of a time value as text. If no parameter is passed then
Now is assumed. Uses international date format rules.
Example:
Writeln DateString ;returns the date of Now as text
Writeln DateString (Tomorrow) ;returns the date of Tomorrow as text
Category: Time String International
Day : Number
Returns the day of the month.
Category: Time
DayOf (Date) : Number
Returns the day of a date. If Date is passed as a string it is
converted automatically.
Example:
DayOf('April 22, 1992') ;returns 22
See Also: TimeOf BadDate
Computer Tyme * MarxMenu * Users Manual Page #126
-----------------------------------------------------------------
Category: Time
DayOfWeek : Number
Returns the day of the week.
0=SUNDAY
1=MONDAY
2=TUESDAY
3=WEDNESDAY
4=THURSDAY
5=FRIDAY
6=SATURDAY
Category: Time
DayOfWeekOf (Date) : Number
Returns the DayOfWeek of a date. If Date is passed as a string it is
converted automatically.
Example:
DayOfWeekOf('April 22, 1992') ;returns 4
See Also: TimeOf BadDate
Category: Time
DecimalSeparator : String
Returns the decimal separator character from the country information.
See Also: TimeSeparator DateSeparator CountryCode
Category: International
Delete (String,Pos,Count)
Deletes characters from string starting at pos for count.
Example:
String = 'ABCDEFGH'
Delete(String,2,3)
This leaves a String containing 'AEFGH'
If count exceeds the length of the string, the string is truncated at
pos.
Computer Tyme * MarxMenu * Users Manual Page #127
-----------------------------------------------------------------
Another use of Delete is to delete elements of an array.
Delete (Array,Position,Count)
This works exactly like the delete command for strings. It delete
elements of an array beginning at Position for Count elements. The
NumberOfElements is adjusted accordingly.
Example:
MyArray[1] = "ONE"
MyArray[2] = "TWO"
MyArray[3] = "THREE"
MyArray[4] = "FOUR"
Delete( MyArray,2,2 )
;MyArray now contains..
MyArray[1] = "ONE"
MyArray[2] = "FOUR"
Category: String Array
DelFile (Name)
Deletes a file by name. FileResult returns a 0 if the file existed and
the delete was successful.
Example:
DelFile( 'C:\NOTES\READ.ME' )
If FileResult = 0
Writeln('C:\NOTES\READ.ME was successfully deleted!')
Else
Writeln('C:\NOTES\READ.ME was NOT deleted successfully!')
EndIf
Category: File
Devices (Array)
Fills array with list of all devices.
Example:
var temp
devices(temp) ;Device list --> array temp
loop temp ;Loop thru the array
writeln temp[loopindex] ;And Print contents
endloop
Category: Array
Computer Tyme * MarxMenu * Users Manual Page #128
-----------------------------------------------------------------
DirectoriesOnly (On/Off)
Forces ReadDirectory to read directories instead of file names.
See Also: ReadDirectory
Category: Directory
DisplayType : Number
Returns the current video card type.
0 = HercMono
1 = CGA
2 = MCGA
3 = EGA
4 = VGA
5 = PGC
MarxMenu also understands the above constant names. For example, if you
want to test for a CGA card:
if DisplayType = CGA then ....
Category: Video
DiskType (Drive) : String
DiskType returns the type of disk of a drive letter. Types recognized
are:
FLOPPY360
FLOPPY720
FLOPPY12
FLOPPY14
RAMDISK
SUBST
HARDDISK
BERNOULI
NOVELL
CDROM
UNKNOWN
INVALID
Example:
Writeln DiskType('F')
This command will actually read floppy drives which could be slow. The
DriveType command can be used to read the floppy drive configuration in
CMOS memory.
Computer Tyme * MarxMenu * Users Manual Page #129
-----------------------------------------------------------------
See Also: DriveType
Category: System
Dispose (Variable)
This command reclaims memory used by a string variable, file variable,
or an array. If you are doing a lot of data manipulation, you might want
to reclaim memory space used by arrays you are done with. The disposed
variable becomes an untyped variable.
Example:
Loop( 20 )
MyArray[LoopIndex] = LoopIndex
;Check to See Also: if number is odd or even
If (MyArray[LoopIndex] Mod 2) = 0
Writeln('MyArray[' + Str(LoopIndex) + '] is an EVEN number.' );
Else
Writeln('MyArray[' + Str(LoopIndex) + '] is an EVEN number.' );
EndIf
EndLoop
;We're finished with the array so reclaim its memory space.
Dispose(MyArray)
Category: Memory Array
DosVersion : Number
Returns the major DOS version number.
See Also: DosVersionString MinorDosVersion
Category: System
DosVersionString : String
Returns the DOS version number as a 4 character string. This function
always returns 2 places past the decimal point. The form of the string
is: #.##
Example
Writeln DosVersionString ;prints 4.01
See Also: DosVersion MinorDosVersion
Category: System String
Computer Tyme * MarxMenu * Users Manual Page #130
-----------------------------------------------------------------
DosWindow (On/Off)
When you set DosWindow on, MarxMenu will not drop out of the menu system
when you use the Execute command. It will give you a display of the DOS
screen within the current window. The program you execute must be a
well-behaved program like DIR or COPY or some of the other DOS commands
that talk to the screen through standard file handles, otherwise is it
possible for the application to corrupt your MarxMenu display.
See Also: Execute
Category: Execution
DoubleLineBox
Selects double line box.
See Also: SingleLineBox BlockBox CustomBox NoBoxBorder
Category: Display
DPMIInstalled : Boolean
Returns True if DPMI services are installed.
See Also: DPMIVersion
Category: System
DPMIVersion : String
DPMIVersion returns the version of the DPMI driver you are using. If
DPMI isn't present it returns an empty string.
See Also: DPMIInstalled
Category: System
DrawBox (column,row,width,height)
Draws a box on the screen. The (column) and (row) are the upper left
corner, (width) and (height) is the box size.
Example:
Explode On
Shadow On
DoubleLineBox
BoxHeaderColor( Yellow,Red )
BoxBorderColor( White, Red )
BoxInsideColor( Yellow,Red )
InverseColor( Black, Gray )
CapsColor( Black, Red )
BoxHeader = ' << Main Menu >> '
DrawBox( 30,10,40,8 )
Computer Tyme * MarxMenu * Users Manual Page #131
-----------------------------------------------------------------
DrawBox also creates a logical layer for several display variables.
These variables include TextColor, InverseColor, CapsColor. It is
important to use these color control commands AFTER the DrawBox command
in order to properly restore the colors of the previous DrawBox.
If you call up a box and upon finishing it adversely affects the colors
of the previous box, you probably used color control commands BEFORE the
DrawBox instead of AFTER.
Category: Display
Drives : Number
Returns the number of drives. This includes drive names that can be
substituted. Most of the time the answer is 5. This relates to your
LastDrive = command in your CONFIG.SYS file.
Category: System
DriveType (Drive) : String
DriveType returns the type of drive of a given drive letter. This is
like DiskType with the exception of how it deals with floppy drives.
DiskType actually tries to read the floppy so if you put a 720k disk in
a 1.4 meg drive then DiskType will return 720. DriveType returns the
type of drive the CMOS is configured for.
See Also: DiskType
Category: System
DvAppNumber : Number
Returns the DesqView application number or DesqView window number.
Category: DesqView
DvFrame (Handle,On/Off)
Turns the DesqView border frame On or Off for a particular task
identified by Handle.
Category: DesqView
Computer Tyme * MarxMenu * Users Manual Page #132
-----------------------------------------------------------------
DvFreeze (Handle)
Freezes a program. The program stops executing.
See Also: DvUnFreeze DvPifExecute DvLastHandle
Category: DesqView
DvHide (Handle)
Hides all output from program making it invisible. The program still
continues to run.
See Also: DvUnHide
Category: DesqView
DvKillTask (Handle)
Kills a program running under DesqView. The handle is the one returned
by DvPifExecute in DvLastHandle.
See Also: DvPifExecute
Category: DesqView
DvLastHandle : Number
Returns a number that is associated with a program running under
DesqView. This number is used to control other programs running under
DesqView. It is set by DvPifExecute.
See Also: DvPifExecute
Category: DesqView
DvLoaded : Boolean
Returns true if DesqView is loaded.
Category: DesqView
DvMoveWindow (Handle,X,Y)
Moves DesqView window upper left corner to position X,Y.
Category: DesqView
Computer Tyme * MarxMenu * Users Manual Page #133
-----------------------------------------------------------------
DvMyHandle : Number
Returns the DesqView handle of the current process.
See Also: DvLastHandle
Category: DesqView
DvPifExecute (Pif File)
Executes another program under DesqView in another window. MarxMenu
stays resident in its original window. The window executes according to
the contents of the DesqView PIF file. The PIF file can be specified by
using the full name. If you leave off the extension, MarxMenu assumes
the extension DVP. If you pass a 2-character name, like the two
characters in the DesqView menus, then MarxMenu will add -PIF.DVP to the
name. If the PIF file is on the path, MarxMenu will find it.
Warning! DesqView must be loaded to run this command.
Example:
DvPifExecute 'BD'
DvPifExecute 'BD-PIF' ;These all execute Big DOS
DVPifExecute 'BD-PIF.DVP'
The task handle is loaded into a variable named DvLastHandle. When the
program starts, it becomes the current top program.
See Also: DvLoaded DvLastHandle
Category: DesqView
DvResizeWindow (Handle,Width,Height)
Changes the size of a DesqView window.
Category: DesqView
DvSetBottom (Handle)
Sets the program associated with the handle to the bottom of the task
stack.
See Also: DvSetTop
Category: DesqView
Computer Tyme * MarxMenu * Users Manual Page #134
-----------------------------------------------------------------
DvSetTop (Handle)
Sets the program associated with the handle to be the top running task.
Using DvMyHandle allows MarxMenu to regain control after starting
another task.
Example:
DvSetTop (DvMyHandle)
See Also: DvSetBottom DvLastHandle
Category: DesqView
DvUnFreeze (Handle)
UnFreezes a program. The program starts executing again.
See Also: DvFreeze DvPifExecute DvLastHandle
Category: DesqView
DvUnHide (Handle)
Reverses the effect of DvHide making program output visible again.
See Also: DvHide
Category: DesqView
Else
Starts lines executed if a condition is not true.
Example:
if X = 1
Writeln 'One'
else
Writeln 'Not One'
endif
See Also: If Then Endif ElseIf
Category: Conditional
Computer Tyme * MarxMenu * Users Manual Page #135
-----------------------------------------------------------------
ElseIf
Used with IF, ELSE, and ENDIF in conditional statements. After one
ElseIf is true, execution continues after the endif statement.
Example:
if X = 1
Writeln 'One'
elseif X = 2
Writeln 'Two'
elseif X = 3
Writeln 'Three'
elseif X = 4
Writeln 'Four'
else
Writeln 'Other'
endif
See Also: If Then Endif Else
Category: Conditional
EmsInstalled : Boolean
Returns True if EMS memory manager is installed.
See Also: EmsVersion
Category: System
EmsVersion : String
EmsVersion returns the version of the EMS driver you are using. If EMS
isn't present it returns an empty string.
See Also: EmsInstalled
Category: System
Computer Tyme * MarxMenu * Users Manual Page #136
-----------------------------------------------------------------
EndComment
Ends a comment block.
Example:
Comment
=======================================
Everything between Comment and EndComment is ignored.
=======================================
EndComment
See Also: Comment
Category: Misc
EndIf
Ends an if statement.
Example:
writeln "EndIf Example"
if DayOfWeekof(Today)=2 ;Code Between IF
Writeln 'This line will only print on Tuesdays' ;and ENDIF will
endif ;run if cond=True
writeln "This line will always execute"
See Also: If Else ElseIf Then
Category: Conditional
EndLoop
Ends a loop statement.
See Also: Loop LoopIndex LoopLimit
Category: Conditional
EndOfFile (FileVar) : Boolean
Returns True if you are at the end of the file.
Example:
Var In
FileAssign (In,'C:\NOTES\READ.ME')
FileOpen (In)
While not EndOfFile (In)
Writeln (FileReadLn (In))
EndWhile
FileClose (In)
Computer Tyme * MarxMenu * Users Manual Page #137
-----------------------------------------------------------------
Category: File
EndProc
Ends a Procedure.
See Also: Procedure Return
Category: Misc
EndWhile
Ends a While statement.
See Also: While
Category: Conditional
EnvFree : Number
Returns the free space in the selected environment.
Example:
if EnvFree
Writeln "WARNING: Environment Memory Critically LOW!!!"
endif
See Also: EnvSize
Category: Environment
EnvSize : Number
Returns the size of the selected environment.
Example:
if EnvSize < 20
Writeln 'Your environment size is less than 20 bytes!!'
endif
See Also: EnvFree
Category: Environment
Computer Tyme * MarxMenu * Users Manual Page #138
-----------------------------------------------------------------
EraseTopWindow
Erases the last window created with DrawBox.
See Also: EraseWindow
Category: Display
EraseWindow (Number)
Erases a window by number. This allows you to erase a window that is not
the top window.
See Also: CurrentWindow SetTopWindow EraseTopWindow
Category: Display
Execute ("command string")
This allows you to execute a program without dropping out of MarxMenu.
MarxMenu remains resident in memory and takes up approximately 50k. No
batch file will be created by MarxMenu.
This is handy if you have a small program you want to run from the menu
but don't want to allow for the time required by MarxMenu to create and
run a batch file. You can also execute some programs in a MarxMenu
window (See Also: DosWindow). You can also execute a program and examine
the return code.
This command can be placed in a progression of menu commands without any
special handling. Under an OnKey statement, you will need use a vertical
bar in front of the command.
Example:
OnKey 'D'
|UseCommand Off
|Execute 'C:\DM.COM' ;Note the COM extension is required here.
Note: If UseCommand is True or On, MarxMenu will load COMMAND.COM to
execute your command. If UseCommand is False, MarxMenu will execute your
file directly without COMMAND.COM. Using COMMAND.COM will execute
slightly slower, use 3.5k more RAM, and allow you to use command lines
just like you would from the DOS prompt.
If you set UseCommand to Off, you will have to include the COM or EXE
extension in the name. If you don't include the extension, MarxMenu will
automatically override UseCommand and load the command processor. If the
command processor is loaded then you won't be able to read the
errorlevel return code from the program you are running.
Computer Tyme * MarxMenu * Users Manual Page #139
-----------------------------------------------------------------
MarxMenu will also use COMMAND.COM if you are piping or redirecting
output to a file. COMMAND.COM is required when running internal DOS
commands like COPY or DIR. It is also required to run batch files.
When UseCommand is off, MarxMenu will search the PATH for the executable
file if it isn't in the current directory.
Not using COMMAND.COM allows you to use the ReturnCode variable to get
the ERRORLEVEL from the subprogram. If COMMAND.COM is loaded, the
ERRORLEVEL of the subprogram is lost.
The ClearScreenFirst (On/Off) controls whether MarxMenu will clear the
screen before you execute.
The PauseAfterExecute (On/Off) allows you to have a pause like the Pause
command in batch files. That way you can read the screen before it
restores the MarxMenu screen. MarxMenu will display "Press any key to
return to MarxMenu."
By setting DosWindow to true MarxMenu will allow some programs to
execute with the display going to a MarxMenu window. For this to work
the program must output it's text to the standard output device.
Programs that write directly to the screen won't work with DosWindow.
Be sure not to load any TSR programs using the Execute command or
MarxMenu will lock up.
See Also: UseCommand DosWindow PauseAfterExecute ClearScreenFirst
Category: Execution
ExistDir (Directory) : Boolean
Used to test whether or not a DIRECTORY exists. It can also test to see
if a disk is inserted in a floppy drive or if a drive exists.
Example:
if not ExistDir 'A:' then Writeln 'Insert disk in drive A:'
See Also: ExistFile
Category: Directory
Computer Tyme * MarxMenu * Users Manual Page #140
-----------------------------------------------------------------
ExistFile : Boolean
Used to test whether or not a file or device exists.
Example:
ExistFile 'MARXMENU.EXE'
ExistFile 'LPT2' ;returns true if LPT2 device exists
See Also: ExistDir
Category: File
ExistOnPath (String) : String
Used to search the existing paths for the command to be executed by
Execute or other function.
Example:
OnKey 'D'
|Execute(ExistOnPath('DM.COM'))
If the file is not found, a null string is returned.
Category: File
ExitCode
This can be set so MarxMenu will return an ErrorLevel that can be used
in a batch file.
Example:
ExitCode = 100
When MarxMenu exits it will use ErrorLevel 100.
Category: Execution
ExitMenu
Causes MarxMenu to exit. If the Bat command is used or batch commands
are used under an OnKey statement then MarxMenu will create a batch file
and set the environment variable MXCMD to point to it. If no batch file
is to be created, and MXCMD hasn't been set to any value then the menu
system will exit by setting MXCMD to MXSTOP.
Category: Execution
Computer Tyme * MarxMenu * Users Manual Page #141
-----------------------------------------------------------------
Exp (Real) : Real
Returns the Exponential of a real. Inverse of Ln.
Category: Math Float
Explode (On/Off)
Turn exploding windows On/Off.
Example:
Explode Off ;Box just appears!
DrawBox 1 1 10 15
Explode On ;Box grows on screen.
Drawbox 20 1 10 15
Category: Display
ExplodeDelay (Number)
Sets the speed of exploding windows. Use this command to adjust the
speed of the exploding windows. Default is 15.
Category: Display
Extension (String) : String
Returns the Extension of a file name or sets the Extension.
Example:
Writeln Extension 'MARXMENU.EXE' ;returns 'EXE'
Example:
var FileName
FileName = 'TEST.MNU'
Extension (FileName) = 'MRX'
Writeln FileName ;this returns 'TEST.MRX'
See Also: NamePart PathPart FilePart
Category: String
FileAppend (FileVar)
Opens a file for access and moves the file pointer to the end of the
file. File writes will start at the end of the file.
Example:
var LogFileName
Computer Tyme * MarxMenu * Users Manual Page #142
-----------------------------------------------------------------
FileAssign(LogFileName,'USER.LOG') ; Assign a filename
FileAppend(LogFileName) ; Use FileAppend move to EOF
FileWriteLn(LogFileName,"This is a test") ;Write to file
FileClose(LogFileName) ;Close File
See Also: FileOpen
Category: File
FileAssign (FileVar,String)
Assigns a file variable to a file name. Files must be given a name
before they can be accessed.
Example:
FileAssign(BatFile,'MARX.BAT')
BatFile is a variable and after the FileAssign, it becomes a file
variable. All access to the file must be done using the file variable.
If an empty string is passed as the filename, MarxMenu will use the
standard console file handles.
See Also: FileOpen
Category: File
FileAttr (String) : Number
Returns the attribute of a file or directory.
Example:
; ATTRDISP.MNU
; ATTRIBUTE BYTE DISPLAY PROGRAM
; Using the FileAttr command. USAGE: "MARXMENU ATTRDISP Filename"
var temp
temp=binstring(fileattr(cmdline),8)
writeln "Menu FileName: " + cmdline + " " + temp
writeln " "
if mid(temp,8,1)="1" then writeln "READ-ONLY FLAG SET"
if mid(temp,7,1)="1" then writeln "HIDDEN FLAG SET"
if mid(temp,6,1)="1" then writeln "SYSTEM FLAG SET"
if mid(temp,3,1)="1" then writeln "ARCHIVE BIT SET"
Category: File
Computer Tyme * MarxMenu * Users Manual Page #143
-----------------------------------------------------------------
FileClose (FileVar)
Closes a file and deallocates the memory space used by the file
variable.
See Also: FileOpen FileAssign
Category: File
FileCreate (FileVar)
Creates a new file. If the file exists, it overwrites the old one.
FileCreate opens the file for output. Do not use FileOpen with
FileCreate.
See Also: FileWriteln FileAssign
Category: File
FileDate (String) : Number
Returns file date as 32 bit integer. See DOS manual for date structure.
This function should not be confused with FileTime which is compatible
with all other MarxMenu time commands.
See Also: FileTime
Category: File
FileFlush (FileVar)
Writes any information that is in the file buffers to disk.
See Also: FileWriteln FileAssign
Category: File
FileLog (FileName,String)
FileLog opens the file if it exists, or creates it if it doesn't exist.
It then seeks to the end of the file and writes the string to the end.
The file is then closed. FileLog is typically used for things such as
usage tracking.
Example:
FileLog('USAGE.LOG','Add This Line!')
Category: File
Computer Tyme * MarxMenu * Users Manual Page #144
-----------------------------------------------------------------
FileOpen (FileVar)
Opens a file for access. FileOpen is not needed if you are using the
ReadTextFile command. The following example copies a text file.
var Inp Out St
FileAssign(Inp,'INPUT.TXT')
FileOpen(Inp)
FileAssign(Out,'OUTPUT.TXT')
FileCreate(Out)
while not EndOfFile(Inp)
St = FileReadln(Inp)
FileWriteln(Out,St)
endwhile
FileClose(Inp)
FileClose(Out)
Category: File
FilePart (String) : String
Returns the file part of a filename.
Example:
NamePart ('C:\MARX\MARXMENU.EXE') ;returns MARXMENU.EXE
See Also: Extension PathPart NamePart
Category: String
FilePos (FileVar) : Number
Returns the current file position in bytes of where you are in a file
that you are reading or writing. You can get back to the same place in
the file by using FileSeek.
See Also: FileSeek
Category: File
FileReadln (FileVar) : String
Reads one line of an open file returning that line as a string.
Example:
Line3 = FileReadln(BatFile)
Computer Tyme * MarxMenu * Users Manual Page #145
-----------------------------------------------------------------
See Also: FileOpen
Category: File
FileRename (Old,New)
Renames a file from old name to new. A file may be moved to a new
directory with this command.
Example:
FileRename ('F:\HOME\MARC\MESSAGE.TXT','F:\HOME\VICKI\MESSAGE.TXT')
Category: File
FileResult : Number
Returns result code from last file IO. Result codes are the same as
Turbo Pascal IOResult codes. These codes usually match the errors
returned in the AX register of DOS commands. 0 indicates no problem.
Example:
DelFile 'TEST.TXT'
if FileResult = 5 then Writeln 'ACCESS DENIED!'
Category: File
FileSeek (FileVar,Number)
Moves the file pointer to a specified place in the file. This allows you
to set the next place in a file that FileReadln will read from.
See Also: FilePos FileReadln
Category: File
FileSize (String) : Number
Returns size of file in bytes.
Example:
FileSize 'CONFIG.SYS'
Category: File
Computer Tyme * MarxMenu * Users Manual Page #146
-----------------------------------------------------------------
FileTime (File) : Time
Returns the time of a file in MarxMenu format. This should not be
confused with FileDate that returns the file time on DOS binary format.
Category: File Time
FileWrite (FileVar,String)
Writes text to a file without a carriage return or line feed.
Example:
FileWrite (Out,Char(12)) ;writes a FormFeed to the file Out
See Also: FileOpen
Category: File
FileWriteln (FileVar,String)
Writes text to a file with a carriage return and a line feed.
Example:
FileWriteln (Out,'This Line')
See Also: FileOpen
Category: File
FixPath
This command reads your path command and verifies that all the paths are
accessible. Any path that isn't accessible is removed from the master
environment. This can be used on network drives to eliminate searching
paths on fileservers that are no longer accessible.
Category: Environment
Floppies : Number
Returns number of floppy drives in your computer.
Category: System
Computer Tyme * MarxMenu * Users Manual Page #147
-----------------------------------------------------------------
ForceExplosion (On/Off)
This changes the explosion status of a window that already exists. This
allows windows to implode that didn't explode.
Category: Display
ForceExtension (String,Ext) : String
This command forces a file extension on a string.
Example:
St = ForceExtension('MAIN.MNU','MRX')
This sets St equal to MAIN.MRX
Category: String
Fraction (Real) : Real
Returns the fractional part of a real.
Example:
Fraction (2.36) ;returns .36
Category: Math Float
FreeDiskSpace (Drive) : Number
Returns free disk space in bytes.
Example:
Writeln (FreeDiskSpace 'C')
FreeDiskSpace only looks at the first character of the string for the
drive letter.
Category: System
FreeEMS : Number
Returns free EMS memory in bytes.
Category: Memory
Computer Tyme * MarxMenu * Users Manual Page #148
-----------------------------------------------------------------
FreeMem(Segment)
FreeMem deallocates memory that was allocated with GetMem. FreeMem
automatically knows how much memory to deallocate.
See Also: GetMem
Category: Memory
FreeMemory : Number
Returns the amount of free memory still available. This is the memory
available to MarxMenu or the amount you would have using the Execute
command.
See Also: ApplicationMemory
Category: Memory
FullLineReturn (On/Off)
The FullLineReturn command is a control parameter affecting the Readln
command. When set to On, subsequent Readlns will auto-force a carriage
return when a user reaches the last character of the input field.
See Also: Readln
Category: String
GetMem (Number) : Segment
GetMem allocates the amount of memory specified in Number and returns
the memory segment where the memory was allocated. The memory segment is
filled with 0s. The maximum size of the memory block is 65504 bytes.
You can then read and write to this memory area using the Mem commands.
Example:
var RamBlock
RamBlock = GetMem(2000) ;allocate 2000 bytes of memory
Mem(RamBlock,0) = 5 ;writes the number 5 to the first byte
See Also: FreeMem
Category: Memory
Computer Tyme * MarxMenu * Users Manual Page #149
-----------------------------------------------------------------
GotoXY (Column,Row)
Move cursor to location column,row in current box.
Example:
GotoXY 35 9
Category: Display Ansi
HexString (Number, Length) : String
HexString converts a number into a base 16 hexadecimal string. If Length
> 0 then the number will have enough leading zeros to make it Length
long. If Length = 0 then leading zeros are removed. Length must be 8 or
less.
Example:
Writeln HexString(253,4) ;returns 00FD
Writeln HexString(253,0) ;returns FD
See Also: BinString
Category: String
HiddenAndSystem (On/Off)
Controls if ReadDirectory will read hidden and system files.
See Also: ReadDirectory
Category: File Directory
HighWord (Number) : Number
Returns the value of the upper 16 bits of a number.
See Also: LowWord
Category: Math
Hour : Number
Return the current hour. 24 hour format.
Category: Time
Computer Tyme * MarxMenu * Users Manual Page #150
-----------------------------------------------------------------
HourOf (Date) : Number
Returns the hour of a date. If Date is passed as a string it is
converted automatically.
Example:
HourOf '6:00 pm' ;returns 18
See Also: TimeOf BadDate
Category: Time
Hundredth : Number
Returns the 1/100 of a second from the system clock. Note that the
system clock timer tick is 1/18 second so don't expect a lot of accuracy
here.
Category: Time
IdleProgram : Procedure
IdleProgram is a variable that when set to the location of a procedure
allows the procedure to run while waiting at the keyboard. This is done
by writing a procedure that will run while waiting for input.
The way you use this is to set an internal variable named IdleProgram to
the Loc of the procedure you want to run as follows:
Example:
IdleProgram = Loc MyProcedure
Note: Do not use parentheses around MyProcedure.
When writing MyProcedure make it as short and quick as possible. As of
now, MyProcedure is called continuously while there is no keyboard
input. You can also use a loop in it as follows.
Procedure MyProcedure
SetItUp
while not KBDReady
{do your thing}
endwhile
PutItBack
EndProc
MarxMenu doesn't automatically exit your procedure or save and restore
anything. If you're writing to the screen you have to put everything
back the way it was.
Computer Tyme * MarxMenu * Users Manual Page #151
-----------------------------------------------------------------
If you want to run a program at a specific time, here's how it can be
done:
Procedure MyProcedure
if Now = TimeOf('11:00pm')
Bat 'NIGHT' ;run NIGHT.BAT
ExitMenu
endif
if Now = TimeOf('5:00')
Bat 'MORNING' ;run MORNING.BAT
ExitMenu
endif
EndProc
To disable IdleProgram run:
Dispose(IdleProgram)
See Also: Run Loc BlankScreenProgram
Category: Execution
If
Used for conditional program control.
Usage:
IF (condition) THEN (statement)
IF (condition)
(statement)
(statement)
ELSEIF (condition)
(statement)
(statement)
ELSE
(statement)
(statement)
ENDIF
Category: Conditional
See Also: Else ElseIf Then EndIf
Computer Tyme * MarxMenu * Users Manual Page #152
-----------------------------------------------------------------
InactiveBox (BoxType)
This is used to select the type of box border to use when a window is
not the current window. If any inactive box type is specified, then when
you execute another DrawBox, the old window's border changes to the
inactive box type. The inactive window also loses its headers and
shadows.
Note that InActiveBox must be used BEFORE the DrawBox command.
Example:
InActiveBox (SingleLineBox) ;switches to single line box if
inactive.
InactiveBox (NoBoxBorder) ;disables InActive effect.
See Also: InactiveBoxColor InactiveShadow
Category: Display
InactiveBoxColor (Foreground,Background)
Selects the color of the inactive box window. If Black on Black is
selected, (default), the inactive box color is the same as the active
box color.
Example:
BoxBorderColor Yellow Blue
InActiveBoxColor Brown Blue
See Also: InactiveBox InactiveShadow
Category: Color
InactiveShadow (On/Off)
When InactiveShadow is set to Off, the window shadow disappears when
then window is not the top window.
See Also: InactiveBox InactiveBoxColor
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #153
-----------------------------------------------------------------
Include (MenuName)
This is used to insert the menu code from another file into the menu
that you are compiling.
Example:
Include 'DOS.MNU'
This will compile DOS.MNU into your present menu as if that whole file
were part of the menu you are working on.
This is useful if you have several menus that share common code. By
moving this common code to a separate file, and using an Include
statement, you can change the common code and update several menus at
once. If you are using overlays, it is a good idea to put your shared
variables in an Include file. This assures that the shared variables
will be the same for all overlays.
Changing an Include file does not cause MarxMenu to recompile
automatically like changing the MNU does. You will have to force it to
compile your menus.
This can be done several ways. You can type MARXCOMP (menu) or you can
just type DEL *.MRX which will cause all the menus to recompile the next
time they are run.
Category: Misc
IncludeDirectories (On/Off)
Controls if ReadDirectory will read directories along with file names.
Please note that the Parent Directory [..] will not be shown.
Example:
Var X
IncludeDirectories On
DirectoriesOnly on
ReadDirectory('*.*',X)
See Also: ReadDirectory
Category: Directory
Computer Tyme * MarxMenu * Users Manual Page #154
-----------------------------------------------------------------
InFile : String
When using StandardIO the input and output files by default use the
console. The input can be overridden by setting InFile to point to a
different file or device.
Example:
InFile = 'INPUT.TXT'
StandardIO
See Also: OutFile StandardIO
Category: File
InMem (TsrName) : Boolean
Inmem returns true if the TSR you are looking for is loaded. This allow
you to do conditionals based on the presence or absence of a TSR. It
will also check for the names of pending batch files.
Example:
if not InMem('BTRIEVE')
Bat 'BTRIEVE.EXE'
endif
See Also: MemoryLoc
Category: Memory
InputBlankChar
InputBlankChar is used with Readln to display the input string area for
entering information into a string. By default it is set to a space
character but can be set to an underline or other characters to make the
field size visible.
Example:
InputBlankChar = '_' ;underline
InputLength = 10
Write 'Enter Postal Code: '
ZipCode = Readln
See Also: Readln
Category: String
Computer Tyme * MarxMenu * Users Manual Page #155
-----------------------------------------------------------------
InputLength
When using Readln to get input from the keyboard, MarxMenu normally
accepts data from the cursor to the edge of the current window. By
setting InputLength to a value, MarxMenu will limit the size of the data
to a specific length.
Example:
InputLength = 10
Write 'Enter Postal Code: '
ZipCode = Readln
InputLength is reset to 0 after each Readln.
See Also: Readln
Category: String
InputString (String)
Preloads a string for the Readln command. The next Readln will have the
InputString on the screen for you to edit or accept. Once Readln
executes, InputString is cleared to a blank string.
Example:
InputString = ReadEnv('USERNAME')
YourName = Readln
See Also: Readln
Category: String
Insert (InsString,OrigString,Pos)
Inserts a string into a string.
Example:
St = 'ABCDEF'
Insert('123',St,4)
St will become 'ABC123DEF'
Category: String
Computer Tyme * MarxMenu * Users Manual Page #156
-----------------------------------------------------------------
InsertMode (On/Off)
Turns insert mode On and Off for Readln commands.
See Also: Readln
Category: Keyboard
Int (Real) : Real
Returns the integer part of a real as a real.
Example:
Int(2.36) ;returns 2.0
Category: Math Float
Integer (Real) : Number
Returns the integer part of a real as an integer. The fractional part is
truncated.
Example:
Int(2.36) ;returns 2
Category: Math Float
Intr (Interrupt,Registers)
Intr works just like MS-DOS except that it lets you choose which
interrupt you want to call. See MS-DOS manual for Details.
See Also: MS-DOS
Category: System
InverseColor (Foreground,Background)
Sets colors for inverse bar used with UseArrows command.
Example:
InverseColor Yellow Mag
Category: Color
Computer Tyme * MarxMenu * Users Manual Page #157
-----------------------------------------------------------------
InvertString (String)
InvertString turns a string around so that characters are in reverse
order. This allows for correct string compares and sorts in Hebrew and
Arabic and other languages that are read from right to left.
Example:
var St
St = 'ABCDE'
InvertString(St)
Writeln St ;Returns 'EDCBA'
Category: String
IpxLoaded : Boolean
Returns True if IPX is loaded
Category: Novell
Jump (Menu)
Jumps to another menu and does not return to original menu.
Example:
Jump 'MYMENU'
See Also: Chain
Category: Execution
KbdReady : Boolean
Returns true if a Key has been pressed.
See Also: ReadKey
Category: Keyboard
KeyEvent (Key) : Procedure
KeyEvent allows you to assign a procedure to a key so that any time the
key is pressed the procedure is called. Setting a key to Nil clears the
key. This command can be used to create global OnKey.
Example:
KeyEvent(F1) = loc ShowHelp ;runs ShowHelp when F1 is pressed
KeyEvent(F1) = Nil ;clears F1 key
Run KeyEvent(F1) ;executes procedure assigned to F1
Computer Tyme * MarxMenu * Users Manual Page #158
-----------------------------------------------------------------
KeyEvents are attached to the current window. New windows inherit the
KeyEvents from their parent window. But if you create a new KeyEvent in
a window and then erase that window the new KeyEvent is erased and the
KeyEvents of the parent window are restored. You can have completely
different KeyEvents for each window and those events become active
whenever the window becomes active.
See Also: ClearKeyEvents
Category: Execution Event
KeyFromMouse : Boolean
Normally mouse activity is translated into keystrokes. This variable is
set to true if the keystroke came from the mouse.
See Also: KbdReady ReadKey
Category: MouseControl
KeySave : String
Stores your keystrokes that you pressed to get to the menu level where
you are at. KeySave is passed to DOS using the SET KSV= command to store
your position in the menu system. To make this work, you must execute
SavePosition On.
This variable can be set by you to force MarxMenu to return to a place
in the menu other than where you are. This allows MarxMenu to suggest a
next step.
See Also: SavePosition
Category: String Environment Execution
KillMusic
This command stops the music and de-allocates the memory used by the
music buffer.
Category: Music
LastDrive : String
Returns the drive letter of the last local drive in the system as set by
CONFIG.SYS. By default, this is drive letter E. On a Novell network the
drive after LastDrive is the first network drive.
Computer Tyme * MarxMenu * Users Manual Page #159
-----------------------------------------------------------------
Category: Novell System
LastKey : String
LastKey returns the last key that was typed at the keyboard. This can be
used after a Readln to determine if the ESC key was pressed or perhaps
the up or down arrow keys.
Sometimes after the press of an ESC key, MarxMenu wants to exit more
levels than you want it to. This can be controlled by setting LastKey =
' ' to stop the abort process.
See Also: Readln OnKey
Category: String
Left (String,Count) : String
Returns string starting at the beginning for count characters.
Example:
Left('ABCDEF',3) ;returns 'ABC'
Category: String
Length (String) : Number
Returns the length of the string or sets the length of a string.
Example:
Length('ABCD') returns 4.
Example:
var St
St = '123456'
Length(St) = 3
Writeln St ;this produces '123'
If you set the length longer than the original string the string is
padded with blanks on the end.
Category: String
Computer Tyme * MarxMenu * Users Manual Page #160
-----------------------------------------------------------------
Ln (Real) : Real
Returns the Natural Logarithm of a real.
Example:
Exp(Ln(5) * 3) = 125
See Also: Exp
Category: Math Float
Loc (Procedure or Variable)
When used with a procedure, Loc returns the location of a procedure for
storing in a variable. The variable is later executed using the Run
command.
When used with a variable, Loc returns the location of a variable rather
than it's contents. Thus B = Loc A sets B to point to A.
Example:
Var A B
B = Loc A
B = 9
Writeln A ;returns 9
Example:
Var A
TestLoc (Loc A)
Writeln A ;returns 9
Procedure TestLoc (B)
B = 9
EndProc
The rule is that all indirect location references are resolved in the
process of evaluating an expression.
Example:
Var A B C D
B = Loc A
C = Loc B
D = Loc C
D = 9
Writeln A ; Returns 9
As you would expect, qualifiers and multidimensional array addressing
works with indirect addressing.
Computer Tyme * MarxMenu * Users Manual Page #161
-----------------------------------------------------------------
Example:
var A B C D E
A[3] = 12
C = 3
B = Loc C
D = Loc E
D[7] = 8
TestLoc (Loc A[B])
Writeln A[B,9,E[7]]
Procedure TestLoc (X)
Writeln X
X[9,D[7]] = 6
Writeln X[9,E[7]]
EndProc
See Also: Run Actual
Category: Variable
Local : Array
Parameters passed to procedures and local variables in a procedure are
elements of an array of local variables. By using the word Local you can
address passed parameters and local variables as if they were elements
of an array.
Example:
Procedure Test (A,B)
var C,D
Writeln A B C D
EndProc
In the above example the variable A is the same as Local[1], B is
Local[2], C is Local[3], and D is Local[4]. The Local command can be
used to pass a varying number of parameters to a procedure as follows:
Example:
Procedure Test
Loop Local
Writeln Local[LoopIndex]
endloop
EndProc
Test (1,2,3,4)
Computer Tyme * MarxMenu * Users Manual Page #162
-----------------------------------------------------------------
This allows the procedure Test to accept and process any number of
parameters you wish to pass to it.
Category: Array
LockWord (word)
Sets a default word for the console activated keyboard lock. When the
screen goes blank, the user has to type the LockWord to unblank the
screen. This is a security feature so that if a user leaves the menu
unattended, it prevents others from tampering with the system.
Example:
LockWord = 'secret'
See Also: LogoffTime BlankTime UseNovPassword
Category: Display
Logoff
Logoff logs you off the network the same way that LogoffTime does except
it does it immediately. See LogoffTime for details as to how.
Example:
OnKey 'L'
|Logoff ;note the use of the '|' under the OnKey statement
See Also: LogoffTime
Category: Execution
LogoffTime : Number
MarxMenu supports automatic logoff after a number of minutes of
inactivity set by LogoffTime. This only has effect while you are in the
menu and not while an application is running. It is set as follows:
LogoffTime = 5 ;sets time to 5 minutes
Setting LogoffTime to 0 disables this feature.
On a Novell network the current drive is changed to the first network
drive letter. Any map roots on this drive are removed. Then it changes
to the \LOGIN directory. Typically the current directory will be set to
F:\LOGIN.
MarxMenu will first look for a batch file in the \LOGIN directory called
OFF.BAT. If it doesn't find it, MarxMenu will look for OFF.BAT on the
PATH. If this isn't found, MarxMenu will look for LOGOFF.EXE. If this
isn't found, then MarxMenu will look for LOGOUT.COM.
Computer Tyme * MarxMenu * Users Manual Page #163
-----------------------------------------------------------------
LOGOFF.EXE and LOGOUT.COM are executed by stuffing the keyboard buffer.
The best way to use this feature is to create an OFF.BAT file in your
\LOGIN directory or on the PATH.
Logging off is a tricky process and requires that everything is done
right in order for it to work. If strange things happen use ECHO ON and
PAUSE in your batch files in order to watch what is happening.
See Also: LockWord Logoff
Category: Execution
Logout
Same as Logoff.
See Also: Logoff LogoffTime
Category: Execution
LongestLine
This system variable is set whenever a text file is read using the
ReadTextFile command. LongestLine is set to the length of the longest
line in the file.
Example:
var temp, temp2
write "Name of file to scan: "
temp=readln
ReadTextFile(temp,temp2)
writeln " "
write "The longest line in " temp " is "
writeln Longestline " Characters."
See Also: ReadTextFile
Category: File String
Loop
MarxMenu has a looping structure that lets you execute a piece of code a
specific number of times. It is used as follows:
Example:
Loop 8
Writeln 'Pass Number ' LoopIndex
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #164
-----------------------------------------------------------------
You start with LOOP (Number) which specifies the number of times to
execute the code between LOOP and ENDLOOP. There are 2 variables
available here for loop control. LoopIndex starts at 1 and is
incremented at each EndLoop. When LoopIndex becomes greater than
LoopLimit, the loop exits. LoopIndex and LoopLimit refer to the
innermost loop.
As loops are nested LoopIndexes and LoopLimits are kept in two arrays;
LoopIndexStack and LoopLimitStack. There is also a variable called
LoopLevel which points to the current loop parameters.
Thus:
LoopIndex is the same as LoopIndexStack[LoopLevel]
LoopLimit is the same as LoopLimitStack[LoopLevel]
You may therefore access outer loop parameters through the loop stacks.
For instance LoopIndexStack[LoopLevel - 1] would refer to the second
innermost loop index. LoopIndexStack[1] refers to the outermost loop.
The loop variables can be read and written to so you can adjust the
looping parameters while inside the loop. You can even adjust the
parameters of outer loops.
You can also pass an array to a loop instead of a number. If an array is
passed MarxMenu will loop for the number of elements in that array.
Example:
Var X
ReadTextFile('MARXREAD.ME',X)
OpenPrinter
;Loop X is the same as Loop NumberOfElements X
Loop X
PrintLn X[LoopIndex]
EndLoop
ClosePrinter
See Also: EndLoop LoopIndex LoopLimit LoopLevel
Category: Conditional
LoopIndex : Number
Returns the index of the loop you are in.
Example:
Loop 5
Writeln LoopIndex ;writes the numbers 1 to 5
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #165
-----------------------------------------------------------------
See Also: Loop EndLoop LoopLimit LoopLevel
Category: Conditional
LoopLevel : Number
Returns the number of nested loops currently running. This includes all
nested loops not just the current procedure.
See Also: Loop EndLoop LoopLimit LoopIndex
Category: Conditional
LoopLimit : Number
Returns the upper limit of the loop you are in.
Example:
Loop 5
Writeln LoopLimit ;writes the number 5, 5 times.
EndLoop
See Also: Loop EndLoop LoopIndex LoopLevel
Category: Conditional
LowerCase (String) : String
Returns the lower case of the string according to international
character rules.
Example:
Writeln LowerCase('ABCDE') ;returns 'abcde'
See Also: UpperCase
Category: String International
LowWord (Number) : Number
Returns the value of the lower 16 bits of a number.
Example:
LowWord -1 ;returns 255
See Also: HighWord
Category: Math
Computer Tyme * MarxMenu * Users Manual Page #166
-----------------------------------------------------------------
MachineName : String
This reads or sets the MachineName for NetBios networks.
Example:
MachineName = IBM ;sets the MachineName
Writeln MachineName ;displays the MachineName
Category: Novell MSNet Vines
MakeListEntry (Local Name, Server Name)
MakeListEntry adds an entry to the network redirection list for
assigning drive letters to network servers or redirecting printer output
to network printers.
Example:
MakeListEntry ('P:','\\TYME\SYS\PUBLIC')
MakeListEntry ('LPT1','\\TYME\LASER')
See Also: AssignList CancelListEntry
Category: Novell MSNet Vines
MarxVersion : String
Returns the version number of the MarxMenu you are running.
Category: String
MasterEnvironment
MasterEnvironment selects the Master Environment for use with
environment access commands.
See Also: ReadEnv SetEnv ReadEnvironment ShellEnvironment
See Also: CurrentEnvironment ParentEnvironment
Category: Environment
Max (Num,Num) : Num
Returns the largest of two numbers or strings.
Example:
Writeln Max(2,3) ;returns 3
See Also: Min
Computer Tyme * MarxMenu * Users Manual Page #167
-----------------------------------------------------------------
Category: Math String Float
MatrixInvert (2D Array)
MatrixInvert reverses the coordinates of a 2-dimensional array. This is
useful when used with ReadAscTextFile to reverse the field and record
layout.
Example:
var Data NameList
ReadAscTextFile('PHONE.LST',Data)
MatrixInvert Data
NameList = Data[1]
Category: Array
McpClass : Number
Returns the math coprocessor class.
0 = None
1 = 8078
2 = 80287
3 = 80387
4 = 80487 (486 CPU)
See Also: McpName CpuClass
Category: System
McpName : String
Returns the name of the marh coprocessor. If there is no math
coprocessor then an empty string is returned. Names include:
8078, 80287, 80387, 80487
See Also: McpClass CpuName
Category: System
Mem (seg,ofs) : Number
Returns the byte at memory location seg:ofs or lets you write to the
byte at seg:ofs.
Example:
X = Mem(40,5) ;reads memory into X
Mem(40,5) = X ;writes X into memory
Computer Tyme * MarxMenu * Users Manual Page #168
-----------------------------------------------------------------
See Also: MemW MemL
Category: Memory
MemL (seg,ofs) : Number
Returns the long integer at memory location seg:ofs or lets you write to
the byte at seg:ofs.
Example:
X = MemL(40,5) ;reads memory into X
MemL(40,5) = X ;writes X into memory
See Also: Mem MemW
Category: Memory
MemSize : Number
Returns total memory size in K. (640 = 640k)
Category: Memory
MemW (seg,ofs) : Number
Returns the word at memory location seg:ofs or lets you write to the
byte at seg:ofs.
Example:
X = MemW(40,5) ;reads memory into X
MemW(40,5) = X ;writes X into memory
See Also: Mem MemL
Category: Memory
MemoryLoc (TsrName) : Number
MemoryLoc returns the memory segment address of the TSR name you
specify. If the TSR isn't in memory it returns a 0.
Example:
Writeln 'Btrieve is at $' HexString(MemoryLoc('BTRIEVE'),4)
See Also: InMem
Category: Memory
Computer Tyme * MarxMenu * Users Manual Page #169
-----------------------------------------------------------------
MenuFileName : String
This returns the name of the current menu file including the complete
path. It can be used under an OnKey statement to edit the current menu
as follows:
Example:
OnKey 'E'
EDIT MenuFileName
Category: String
MenuKeyBuffer
This is an internal MarxMenu variable. It is where the environment
variable KSV= is read. Characters in this string variable are treated as
if someone had typed them from the keyboard.
This variable can be set to blank in order to override the effects of
SET KSV= or can be set to a different value in order to automatically
make selections as if they were typed in.
See Also: SavePosition KeySave
Category: Keyboard
MhsDirectory : String
Returns the directory of MHS.
Example:
Writeln MhsDirectory ; '\\TYME\SYS\MHS'
Category: MHS Directory
MhsMailDirectory : String
Returns the mail directory of MHS.
Example:
Writeln MhsMailDirectory ; '\\TYME\SYS\MHS\MAIL'
Category: MHS Directory
Computer Tyme * MarxMenu * Users Manual Page #170
-----------------------------------------------------------------
MhsReadFile (FileName,Header,Message)
MhsReadFile reads FileName into two arrays. The Header array contains the
MHS message header. The Message array contains the MHS message.
Example:
var MailFiles Mail Headers X
WholeFileNames
ReadDirectory(MhsUserDirectory + '\MHS\*.',MailFiles)
Loop MailFiles
MhsReadFile(MailFiles[LoopIndex],Mail[LoopIndex],Headers[LoopIndex])
EndLoop
Loop Mail
X = LoopIndex
Loop Headers[X]
Writeln Headers[X,LoopIndex]
EndLoop
Loop Mail[X]
Writeln Mail[X,LoopIndex]
EndLoop
EndLoop
Category: MHS
MhsSendDirectory : String
Returns the directory of MHS where messages are placed to be sent.
Example:
Writeln MhsSendDirectory ; '\\TYME\SYS\MHS\MAIL\SND'
Category: MHS Directory
MhsUserDirectory : String
Returns the user directory of MHS.
Example:
Writeln MhsMailDirectory ; '\\TYME\SYS\MHS\MAIL\USERS\MARC'
Category: MHS Directory
Computer Tyme * MarxMenu * Users Manual Page #171
-----------------------------------------------------------------
Mid (string,pos,count) : String
Returns a string starting at pos for count.
Example:
Writeln Mid('ABCDEFG',2,3) ;returns 'CDE'
Mid also allows you to write into a string at a specified point.
Example:
St = 'ABCDEFG'
Mid(St,3) = '1' X becomes 'AB1DEFG'
Mid(St,3) = '123' X becomes 'AB123FG'
Mid(St,3) = '1234567' X becomes 'AB1234567'
Mid(St,9) = '12' X becomes 'ABCDEFG 12'
Category: String
Min (Num,Num) : Num
Returns the smallest of two numbers or strings.
Example:
Writeln Min(2,3) ;returns 2
See Also: Max
Category: Math String Float
MinorDosVersion : Number
Returns the minor DOS version number.
See Also: DosVersion DosVersionString
Category: System
Minute : Number
Returns the current minute.
Category: Time
Computer Tyme * MarxMenu * Users Manual Page #172
-----------------------------------------------------------------
MinuteOf (Date) : Number
Returns the minute of a date. If Date is passed as a string it is
converted automatically.
Example:
MinuteOf '6:15 pm' ;returns 15
See Also: TimeOf BadDate
Category: Time
MkDir (String)
Makes a new directory. The FileResult variable returns the DOS result
error code. A zero in FileResult indicates success.
Example:
MkDir 'C:\MARX'
See Also: ChDir RmDir
Category: File Directory
Mod : Operator
Returns the remainder of the division of two numbers.
Example:
25 mod 7 = 4
Category: Math
ModifyPath
The MarxMenu directory should be in the search path. This is because if
you change directories, MarxMenu may not be able to find the menu files.
MarxMenu will now test the PATH= environment variable before it writes
the batch file to execute a program. If the MarxMenu path is not
included, MarxMenu will add the path to the Master Environment if it
can.
If for some reason you don't want to allow MarxMenu to modify the master
environment, use the command:
ModifyPath Off
Category: Environment
Computer Tyme * MarxMenu * Users Manual Page #173
-----------------------------------------------------------------
Month : Number
Returns current month.
Category: Time
MonthOf (Date) : Number
Returns the month of a date. If Date is passed as a string it is
converted automatically.
Example:
MonthOf 'April' ;returns 4
See Also: TimeOf BadDate
Category: Time
Mouse
MarxMenu normally uses the mouse if present. If you don't want to use
the mouse you can use the command:
Mouse Off
To turn the mouse back on type:
Mouse On
The mouse is actually switched on and off at the point when MarxMenu
waits at the keyboard for a keypress.
Mouse Sensitivity can be set for individual workstations on a network by
setting environment variables MouseX and MouseY as follows:
Set MouseX=15
Set MouseY=25
See Also: MouseHorizontal MouseVertical
Category: System MouseControl
MouseHorizontal (Number)
Controls the horizontal sensitivity of the mouse. The larger the number,
the less sensitive the mouse. Default is 25.
Example:
MouseHorizontal = 25
Computer Tyme * MarxMenu * Users Manual Page #174
-----------------------------------------------------------------
See Also: MouseVertical Mouse
Category: MouseControl
MouseIRQ : Number
Returns the interrupt number that the mouse driver is using.
Category: System MouseControl
MouseType : String
Reurns the type of mouse being used. If a mouse driver isn't present it
returns an empty string.
Mouse Types: BUS, SERIAL, HP, INPORT, PS2, UNKNOWN
Category: System MouseControl
MouseVersion : String
MouseVersion returns the version of the mouse driver you are using. If a
mouse driver isn't present it returns an empty string.
Category: System MouseControl
MouseVertical (Number)
Controls the vertical sensitivity of the mouse. The larger the number,
the less sensitive the mouse. Default is 15.
Example:
MouseVertical = 15
See Also: MouseHorizontal Mouse
Category: MouseControl
MoveWindow (Horizontal,Vertical)
Moves top window. If Horizontal is negative motion is left. If
Vertical is negative, motion is up.
Example:
MoveWindow -3 4 ;moves window 3 spaces left and 4 down
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #175
-----------------------------------------------------------------
MsDos (Registers)
MsDos calls the interrupt 21h system call using values passed in an
array of 10 numbers. The array is set up using predefined Qualifiers
that represent the registers that are passed. These qualifiers are:
AX BX CX DX DI SI DS ES BP FL
Example: Get Current Drive
var Reg
Reg.AX = $1900
MsDos (Reg)
Writeln Char(LowWord(Reg.AX) + 1) ':' ;writes C:
See Also: Intr
Category: System
MxCmd : String
This is an internal string variable that is written to the environment
variable MXCMD. This variable can be written to control what MarxMenu
will write to the Shell Environment. If this variable is written to, it
overrides anything that MarxMenu automatically writes.
Example:
OnKey 'A'
|MxCmd = 'SHUTDOWN.BAT'
|ExitMenu
Category: Environment String Execution
NamePart (String) : String
Returns the name part of a file name.
Example:
NamePart ('C:\MARX\MARXMENU.EXE') ;returns MARXMENU
See Also: Extension PathPart FilePart
Category: String
Computer Tyme * MarxMenu * Users Manual Page #176
-----------------------------------------------------------------
NetworkVersion : Boolean
Returns true if you are running the network version of MarxMenu.
Category: Misc
NextWord (String) : String
This command returns the next logical word of a string variable and
removes the string from the original string.
Example:
StringA = 'one two three'
StringB = NextWord(StringA)
StringB contains 'one'
StringA contains 'two three'
Category: String
Nil
Nil returns a zero or empty value for any type data. As a boolean Nil
returns False. As a number Nil returns 0. As a string, Nil returns an
empty string.
Category: Constants
NoBoxBorder
Use this command if you don't want a border around the menus.
See Also: SingleLineBox DoubleLineBox BlockBox CustomBox
Category: Display
NoExit
Prevents ESC key from allowing you to exit menu. To exit, you must
execute the ExitMenu command. This could be password protected.
See Also: ExitMenu
Category: Execution
Computer Tyme * MarxMenu * Users Manual Page #177
-----------------------------------------------------------------
Not : Operator
Returns logical Not if operators are boolean; or bitwise Not if
operators are numeric.
Example:
if Not ExistDir('C:\MARX') then Writeln 'Marx not Installed!'
Not(0) = -1
See Also: And Or Xor
Category: Math Boolean
NotesLeft : Number
NotesLeft returns the number of notes left in the music buffer to play.
The music buffer is self-adjusting and can store a day's worth of music.
Category: Music
NotesPlayed : Number
Returns the number of notes played. If NotesLeft ever reaches 0,
NotesPlayed also is set to 0.
Category: Music
NovAccountExpDate (UserName) : Date
Returns the Novell account expiration date. You must be logged in to be
able to read this.
Example:
DaysToExpire = NovAccountExpDate(UserName) - Today / SecondsInDay
Category: Bindery Time
NovAddUserToGroup (User,Group)
Adds a user to a group and updates GROUPS_I'M_IN, GROUP_MEMBERS, and
SECURITY_EQUALS properties.
Example:
NovAddUserToGroup ('MARC','EVERYONE')
See Also: NovRemoveUserFromGroup
Category: Bindery
Computer Tyme * MarxMenu * Users Manual Page #178
-----------------------------------------------------------------
NovAddToSet (Obj,Prop,ObjType,MemberObj,MemberType)
Adds an object to a property that is a set property.
Example: Add a user to a group
NovAddToSet(Group,'GROUP_MEMBERS',2,User,1)
NovAddToSet(User,"GROUPS_I'M_IN",1,Group,2)
NovAddToSet(User,'SECURITY_EQUALS',1,Group,2)
See Also: NovDeleteFromSet NovSetProperty
Category: Bindery
NovAttach (Server)
NovAttach is used to create a software link between you and a server,
usually a second server. It must be followed by a NovLogin command to
log you into the server if you want to do anything useful there.
Example:
NovAttach 'TYME'
See Also: NovDetach
Category: Novell
NovAttachedServers (Array)
Returns a list of servers you are already attached to.
Example:
var Servers
NovAttachedServers(Servers)
Loop Servers
Writeln Servers[LoopIndex]
EndLoop
See Also: NovServers
Category: Novell Array
NovAutoDetach (On/Off)
When using MarxMenu to log into a Novell network, MarxMenu will detach
from the file server, if NovAutoDetach is on, when the screen blanker
kicks in, and reattach when the screen is restored. This keeps the
workstation from tying up a connection number while waiting to log in.
If you want to use a workstation as a print server without being logged
in you will want to set this to Off.
Computer Tyme * MarxMenu * Users Manual Page #179
-----------------------------------------------------------------
Default is Off.
Category: Novell
NovBinderyAccess : Number
NovBinderyAccess returns the users bindery access level.
0 - Not logged in.
1 - Logged in.
2 - Object Access.
3 - Supervisor Access.
Category: Bindery
NovBroadcastMode (Mode)
This reads or sets the message broadcast mode.
Example:
Writeln NovBroadcastMode
NovBroadcastMode = 3
Modes:
0 - All Messages, same as running CastOn
1 - Server messages only, same as running CastOff
2 - Same as 0 but user has to poll server for messages
3 - Same as 1 but user has to poll server for messages
See Also: NovSendMessage NovGetMessage
Category: Novell
NovCaptureCopies (Port) : Number
NovCaptureCopies reads or sets the number of copies to print for a
particular port.
Example:
NovCaptureCopies (2) = 5 ;Sets LPT2 to print 5 copies
Writeln NovCaptureCopies (2) ;displays the copies setting on LPT2
See Also: NovCaptureQueue
Category: Novell Printer
Computer Tyme * MarxMenu * Users Manual Page #180
-----------------------------------------------------------------
NovCaptureFF (Port) On/Off
NovCaptureFF reads or sets the printer Form Feed function of a
particular port.
Example:
NovCaptureFF (2) On ;Sets LPT2 Form Feed to On
Writeln NovCaptureFF (2) ;displays the Form Feed setting on LPT2
See Also: NovCaptureQueue
Category: Novell Printer
NovCaptureFile (Port) File
This command is used to capture the output from an LPT port to a
specified file. If output is set to an empty string then this command
performs the same function as an endcapture.
Example:
NovCaptureFile (1) = "PRINTER.TXT" ;Captures LPT1 output to File.
NovCaptureFile (1) = "" ;Ends Capture of Port.
See Also: NovCaptureQueue
Category: Novell Printer
NovCaptureFlush (Port)
This commands flushes any data present in a Netware Print queue to
the printer.
Example:
NovCaptureFlush (2) ;Flush any data in queue on port 2
See Also: NovCaptureQueue
Category: Novell Printer
NovCaptureForm (Port) : Number
NovCaptureForm reads or sets the printer form of a particular port.
Example:
NovCaptureForm (2) = 3 ;Sets LPT2 to form 3
Writeln NovCaptureForm (2) ;displays the form setting on LPT2
See Also: NovCaptureQueue
Computer Tyme * MarxMenu * Users Manual Page #181
-----------------------------------------------------------------
Category: Novell Printer
NovCaptureQueue (Port)
Returns the name of the queue that the port is being captured to. A nul
string indicates capturing is not active. This command can also be used
to start capturing and set the queue to capture. A server can also be
specified.
Example:
Writeln NovCaptureQueue (2) ;shows capture queue for LPT2
NovCaptureQueue (2) = 'LASER' ;captures LPT2 to server Laser Printer
NovCaptureQueue (2) = 'TYME/LASER' ;specifies server TYME
NovCaptureQueue (2) = '' ;End Capture on LPT2
Category: Novell Printer
NovCaptureReset (Port) : String
NovCaptureReset can read or set the reset string for a print queue.
Example:
NovCaptureReset (1) = Esc + char($15)
Writeln NovCaptureReset (1) ;reads the capture setup string
See Also: NovCaptureSetup
Category: Novell Printer
NovCaptureSetup (Port) : String
NovCaptureSetup can read or set the setup string for a print queue.
Example:
NovCaptureSetup (1) = Esc + char($15)
Writeln NovCaptureSetup (1) ;reads the capture setup string
See Also: NovCaptureReset
Category: Novell Printer
NovCaptureTabSize (Port) : Number
NovCaptureTabSize reads or sets the printer TabSize of a particular
port. Range is 1 - 18.
Example:
NovCaptureTabSize (2) = 8 ;Sets LPT2 TabSize to 8 spaces
Writeln NovCaptureTabSize (2) ;displays the TabSize setting on LPT2
Computer Tyme * MarxMenu * Users Manual Page #182
-----------------------------------------------------------------
See Also: NovCaptureQueue
Category: Novell Printer
8
NovCaptureTimeOut (Port) : number
NovCaptureTimeOut reads or sets the printer TimeOut of a particular
port.
Example:
NovCaptureTimeOut (2) = 10 ;Sets LPT2 to 10 second TimeOut
Writeln NovCaptureTimeOut (2) ;displays the TimeOut setting on LPT2
See Also: NovCaptureQueue
Category: Novell Printer
NovCaptureUseBanner (Port)
This reads or sets whether or not a print banner is used.
Example:
Writeln NovCaptureUseBanner (2) ;displays if LPT2 is using a banner
NovCaptureBanner (2) = On ;sets banner to On for LPT2
See Also: NovCaptureQueue
Category: Novell Printer
NovChangePassword (OldPassword,NewPassword)
Changes the Novell users password from OldPassword to NewPassword.
Example:
NovChangePassword('OLDPASS','NEWPASS')
See Also: NovChangeObjPassword
Category: Bindery
NovChangeObjPassword (Obj, Type, OldPassword, NewPassword)
NovChangeObjPassword is like NovChangePassword except it allows you to
change the password on other objects than yourself. Type refers to the
object type. Users are type 1.
Example:
NovChangeObjPassword('DAN',1,'POTATOE','POTATO')
Computer Tyme * MarxMenu * Users Manual Page #183
-----------------------------------------------------------------
See Also: NovChangePassword
Category: Bindery
NovCleanVolumeName (String) : String
Returns a string containing the server and volume name of a filename or
directory.
Example:
Writeln NovCleanVolumeName('L:') ;Returns 'MARX/SYS:LOGIN'
See Also: CleanFileName TrueName
Category: Novell
NovClearConnection (Connection Number)
Disconnects a specific connection number from the server. Requires
console operator rights to use this command.
Example:
NovClearConnection 2
Category: Novell
NovCloseBindery
Closes the Novell bindery for access.
See Also: NovOpenBindery
Category: Bindery
NovCloseSemaphore (Name)
This closes semaphore Name. If there are no other users using this
semaphore, it is deleted.
Example:
NovCloseSemaphore 'LOTUS'
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #184
-----------------------------------------------------------------
NovConnection (ServerName) : Number
This returns your workstation's logical connection number to the server
specified by ServerName. The ServerName parameter is optional and if not
specified then the connection number returned is the connection number
on the default server. A zero indicates that you are not connected to
any servers.
Example:
Var Serv1,Serv2
Serv1 = 'TYME'
Serv2 = 'TSS'
Writeln "I'm Connection " NovConnection(Serv1) " on Server "+Serv1
Writeln "I'm Connection " NovConnection(Serv2) " on Server "+Serv2
Category: Novell
NovConnectionsInUse : Number
Returns the number of connections in use.
Example:
Writeln 'There are ' NovConnections ' connections in use.'
Category: Novell
NovConsoleOperator : Boolean
This returns true if the user has Console Operator privileges. This can
come in handy when you are trying to determine who gets access to the
command line.
Example:
OnKey Esc
|if NovConsoleOperator
| ExitMenu
|endif
Category: Novell
NovCreateObject (Name, ObjectType)
Creates a bindery object of a specific object type. If NovStaticObject
is set to true, then the object will be permanent unless it is deleted.
If set to false, then the object will be automatically deleted if the
file server is rebooted.
Example:
Computer Tyme * MarxMenu * Users Manual Page #185
-----------------------------------------------------------------
;- This example creates a new user
var
UserName
UserName = 'TIMESYNC'
;- Delete object if it already exists
NovDeleteObject(UserName,1);
NovStaticObject On ;Static Object
NovObjectSecurity $31
NovCreateObject (UserName,1)
NovStaticProperty On
NovSetProperty On
NovPropertySecurity $32
NovCreateProperty(UserName,'SECURITY_EQUALS',1)
NovPropertySecurity $31
NovCreateProperty(UserName,"GROUPS_I'M_IN",1)
;- Copies login control from the supervisor
NovSetProperty Off
NovPropertySecurity $32
NovCreateProperty(UserName,'LOGIN_CONTROL',1)
NovPropertyValues(Item,'SUPERVISOR','LOGIN_CONTROL',1)
NovWritePropValue(Item,UserName,'LOGIN_CONTROL',1)
NovCreateProperty(UserName,'ACCOUNT_BALANCE',1)
NovWritePropValue(Set [''],UserName,'ACCOUNT_BALANCE',1)
NovPropertySecurity $22
NovCreateProperty(UserName,'MISC_LOGIN_INFO',1)
NovPropertySecurity $31
NovCreateProperty(UserName,'IDENTIFICATION',1)
NovWritePropValue(Set ['Time Sync User'],UserName,'IDENTIFICATION',1)
NovChangeObjPassword(UserName,1,'','SETTIME')
;- Gives user Console Operator access.
NovAddToSet(NovDefaultServer,'OPERATORS',4,UserName,1)
Computer Tyme * MarxMenu * Users Manual Page #186
-----------------------------------------------------------------
NovObjectSecurity controls who can access the object. The default
security is $11 which allows anyone logged into the network to access
the object for both read and write. In this example the security of
$31 allows anyone logged in to read the object, but only users with
supervisor equivalence can write/modify/delete it. With some objects
as in the above example where we create a new Netware group, you must
also assign the necessary properties before the object is functional
to Netware.
See Also: NovStaticObject NovObjectSecurity NovDeleteObject
See Also: NovCreateProperty
Category: Bindery
NovCreateProperty (Object, Prop, ObjType)
Creates a property on the object. The security of the property is
controlled by setting the variable NovPropertySecurity. You can also
control if the property is an item property or a set property. This is
done by setting NovSetProperty to True or False.
If NovStaticProperty is true then the property will remain until someone
deletes it. If it is not static (dynamic) then it will be deleted if the
server is rebooted.
A set property contains a list of objects. An item property contains a
value up to 128 bytes long. The value can be anything.
Example:
; Create a Group Example.
NovDeleteObject ('TESTGROUP',2)
NovStaticObject On
NovObjectSecurity $31
NovCreateObject ('TESTGROUP',2)
NovSetProperty On
NovStaticProperty On
NovPropertySecurity $31
NovCreateProperty('TESTGROUP','GROUP_MEMBERS',2)
See Also: NovStaticProperty NovPropertySecurity NovDeleteProperty
See Also: NovCreateObject
Category: Bindery
Computer Tyme * MarxMenu * Users Manual Page #187
-----------------------------------------------------------------
NovDefaultServer : String
Returns the name of the default file server.
Example:
Writeln NovDefaultServer
Category: Novell
NovDeleteFromSet (Obj,Prop,ObjType,MemberObject,MemberType)
Deletes an object from a property that is a set property.
Example:
To Remove a user to a group:
NovDeleteFromSet(Group,'GROUP_MEMBERS',2,User,1)
NovDeleteFromSet(User,"GROUPS_I'M_IN",1,Group,2)
NovDeleteFromSet(User,'SECURITY_EQUALS',1,Group,2)
See Also: NovAddToSet NovSetProperty
Category: Bindery
NovDeleteObject (Object,Type)
Deletes an object from the bindery.
Example:
NovDeleteObject('JOE',1)
Category: Bindery
NovDeleteProperty (Obj,Prop,Type)
NovDeleteProperty deletes a property from an object.
Example:
NovDeleteProperty('TEST','WASTE',2)
Category: Bindery
NovDetach (Server)
This is used to drop the connection to a server. It also logs you off.
Example:
NovDetach 'TYME'
Computer Tyme * MarxMenu * Users Manual Page #188
-----------------------------------------------------------------
See Also: NovAttach
Category: Novell
NovDownServer
Takes the default file server down if there are no files open. You must
be supervisor equivalent to user this command.
See Also: NovForceDownServer
Category: Novell
NovEndCapture (Port)
Ends printer capture for LPT ports.
Example:
NovEndCapture (1) ;cancels LPT1 capture
See Also: NovCaptureQueue
Category: Novell Printer
NovForceDownServer
Takes the default file server down regardless of open files. You must be
supervisor equivalent to use this command.
See Also: NovDownServer
Category: Novell
NovFreeDirSlots (Path) : Number
Returns the number of free directory slots for this volume.
Example:
Writeln NovFreeDirSlots 'SYS:'
Writeln NovFreeDirSlots 'F:'
See Also: NovTotalDirSlots
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #189
-----------------------------------------------------------------
NovFreeVolumeSpace (Path) : Number
Returns the free file space of the volume in bytes.
Example:
Writeln NovFreeVolumeSpace 'SYS:'
Writeln NovFreeVolumeSpace 'F:'
See Also: NovTotalVolumeSpace NovUsedVolumeSpace
Category: Novell
NovFullName (User)
Returns the Full Name of the user as set by Syscon. If NovFullName is
used without a parameter then MyLoginName is assumed.
Example:
Writeln NovFullName 'MARC' ;Writes Marc Perkel
See Also: NovLoginName
Category: Bindery
NovGetConnections (Array,Name,Type)
NovGetConnections return an array of connection numbers that a specified
user or other object is attached to. For users use type 1.
Example:
var Connections
NovGetConnections(Connections,'VICKI',1)
Loop Connections
NovSendMessage('The Princess Called!',Connections[LoopIndex])
EndLoop
Category: Bindery
NovGetMessage : String
When in broadcast mode 2 or 3 this polls the server for stored messages
and returns them if found.
Example:
NovBroadcastMode = 3
Writeln NovGetMessage
See Also: NovSendMessage NovBroadcastMode
Computer Tyme * MarxMenu * Users Manual Page #190
-----------------------------------------------------------------
Category: Novell
NovGraceLoginReset (User) : Number
Returns the number of grace logins that Novell resets when the user
changes his password.
Example:
Writeln NovGraceLoginReset (NovMyLoginName)
If the User parameter is not included, MarxMenu will assume the current
user.
You can also set the grace login reset as follows:
NovGraceLoginReset = 5
See Also: NovGraceLogins
Category: Bindery
NovGraceLogins (User) : Number
Returns the number of grace logins the user has left.
Example:
Writeln 'You have ' NovGraceLogins (NovMyLoginName) ' left!'
If the User parameter is not included, MarxMenu will assume the current
user.
You can also set the grace logins as follows:
NovGraceLogins = 5
See Also: NovPasswordExpDate NovGraceLoginReset
Category: Bindery
NovGroupMembers (Group,Array)
This reads all the members of Group and puts them into an array.
Example:
var Members
NovGroupMembers ('EVERYONE',Members)
Loop Members
Writeln Members[LoopIndex]
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #191
-----------------------------------------------------------------
Category: Bindery Array
NovGroups (Array)
Fills array with list of all groups.
Example:
var Groups
NovGroups (Groups)
Loop Groups
Writeln Groups[LoopIndex]
EndLoop
See Also: NovUsersLoggedIn NovUsers NovPrintQueues NovServers
Category: Bindery
NovInGroup (Group) : Boolean
Returns true if you are in the group.
Example:
If NovInGroup ('PAYROLL') then Writeln 'Accounting'
Category: Bindery
NovLastLoginDate (User) : Date
Returns the date and time the user last logged in.
Example:
DaysSinceLogin = NovLastLoginDate(UserName) - Today / SecondsInDay
If the User parameter is not included, MarxMenu will assume the current
user.
Category: Bindery Time
NovLogin (Name,Password)
This logs you into a file server. It is different than the Novell's
login program in that it doesn't execute any login scripts. It merely
gets you in. You can include the preferred server with the name.
Example:
NovLogin ('MARC','PASSWORD')
NovLogin ('TYME/MARC','PASSWORD')
Computer Tyme * MarxMenu * Users Manual Page #192
-----------------------------------------------------------------
NovLogin will automatically attach to the file server for you and
preserve all default and preferred server settings.
The variable NovResult is set to 0 or 223 if successful. The 223 result
indicated a grace login.
If you are using Netware 3, MarxMenu shells a program named SUBLOGIN.EXE
which does encrypted passwords. This program needs to be on the search
path. If you are using MarxMenu to log into the network the you will
need a copy of SUBLOGIN in the LOGIN directory.
If you don't use SUBLOGIN you will have to go to the server console and
type:
SET ALLOW UNENCRYPTED PASSWORDS = ON
See Also: NovDetach
Category: Novell
NovLoginName (Connection) : String
This returns the login name of the user at any specified connection.
This can also be used to see who else is on the network. If no
connection is specified, the current connection is assumed.
Example:
Writeln NovLoginName ;name of user on this connection
Writeln NovLoginName (2) ;name of user on connection 2
See Also: NovFullName
Category: Bindery
NovLogout
This logs you off the server. Warning! Make sure that you are running
MarxMenu from a local drive and not the server you are logging out of.
MarxMenu needs access to overlays within MARXMENU.EXE and a Logout can
cut off access. This command automatically runs FixPath.
See Also: FixPath Logoff LogoffTime
Category: Novell Vines
Computer Tyme * MarxMenu * Users Manual Page #193
-----------------------------------------------------------------
NovMapDrive (Drive,Directory)
This will map a drive letter to a directory like the Novell MAP
command does. You may specify volume names and server names.
Example:
NovMapDrive ('J','TYME2/SYS:PUBLIC\DOS')
Mapping a drive to a nul string ('') deletes the drive map.
See Also: NovMapRoot
Category: Novell
NovMapRoot (Drive,Path)
NovMapRoot works like Novell's MAP ROOT command. It allows you to map a
drive letter to a subdirectory and make it look like the root directory
of that drive. You may specify volume names and server names.
Example:
NovMapRoot('P','TYME/SYS:PUBLIC')
P:\ is the same as the TYME/SYS:PUBLIC directory
See Also: NovMapDrive
Category: Novell
NovMaxConnections : Number
Returns the maximum number of connections that your Netware will allow.
Category: Novell
NovMinPasswordLength (User) : Number
Returns the minimum length of the password that Novell will accept for a
new password.
Example:
Writeln NovGraceLoginReset (NovMyLoginName)
If the User parameter is not included, MarxMenu will assume the current
user.
Category: Bindery
Computer Tyme * MarxMenu * Users Manual Page #194
-----------------------------------------------------------------
NovMyLoginName : String
This returns the login name of the user.
Example:
Writeln NovMyLoginName
Category: Bindery
NovMyPassword (Password) : Boolean
Novell won't let you read the password, but it will let you guess and
tell you if you're right. This routine returns true if the password
passed is the correct password.
Example"
var Pass
Pass = Readln
if NovMyPassword (Pass)
;Do Something
else
Writeln 'Bad Password!'
endif
Category: Bindery
NovMyPrintQueues (Array)
Returns a list of all print queues that the user has access too.
Example:
var Queues
NovMyPrintQueues (Queues)
Loop Queues
Writeln Queues[LoopIndex]
EndLoop
See Also: NovPrintQueues
Category: Bindery Array
NovObjectID (User) : String
NovObjectID returns the users Novell object identification code. This is
the same as the name of the users mail directory.
Example:
MailDir = 'F:\MAIL\' + NovObjectID (NovMyLoginName)
Computer Tyme * MarxMenu * Users Manual Page #195
-----------------------------------------------------------------
Category: Bindery
NovObjects (2D Array)
NovObjects reads all objects from the bindery returning a 2-dimensional
array containing all object names and object types.
Example:
NovObjects (X)
Loop X
Writeln X[LoopIndex,1] ' ' X[LoopIndex,2]
EndLoop
Common Object Types:
1 - User
2 - Group
3 - Print Queue
4 - File Server
5 - Job Server
6 - Gateway
7 - Print Server
See Also: NovScanProperties NovPropertyValues
Category: Bindery Array
NovObjectSecurity : Number
NovObjectSecurity is used when objects are created to determine who can
read or write the object. The number is one byte. The upper 4 bits
control who can read the object, the lower 4 bits control who can write
to the object.
0000 Anyone
0001 Logged In
0010 Only your Object
0011 Supervisor
0100 Netware Itself
The default is $11 (00010001) which is anyone logged in can read or
write to the object.
NovObjectSecurity can also read and set the security of an existing
object.
Example:
NovObjectSecurity('MARXMENU',600) = $13
Writeln NovObjectSecurity('MARXMENU',600)
Computer Tyme * MarxMenu * Users Manual Page #196
-----------------------------------------------------------------
See Also: NovCreateObject NovStaticObject NovPropertySecurity
Category: Bindery
NovOpenBindery
Opens the Novell bindery for access.
See Also: NovCloseBindery
Category: Bindery
NovOpenSemaphore (Name,Value)
This opens semaphore Name and assigns it an initial value. If the
semaphore already exists, the value isn't changed. The number of
semaphore users is increased by one if this user hasn't already opened
this semaphore name.
Example:
NovOpenSemaphore ('LOTUS',0)
See Also: NovCloseSemaphore NovSemaphoreUsers
Category: Novell
NovPasswordExpDate (UserName) : Date
Returns the Novell password expiration date. You must be logged in to be
able to read this.
Example:
DaysToExpire = NovPasswordExpDate(UserName) - Today / SecondsInDay
See Also: NovGraceLogins
Category: Bindery Time
NovPreferredServer : String
Returns the name of the preferred file server. This is set with the
NovSetPreferredServer command.
Normally the default server is controlled by the current directory. If a
preferred server is set then this default is changed. Setting the
preferred server to blank resets the default server. When MarxMenu
terminates the Preferred server setting is terminated.
Computer Tyme * MarxMenu * Users Manual Page #197
-----------------------------------------------------------------
Category: Novell
NovPrimaryServer : String
Returns the name of the primary file server. This is the one you first
logged into.
Category: Novell
NovPrintQueues (Array)
Fills array with list of all print Queues. The user might not have
access rights to all these queues.
Example:
var Queues
NovPrintQueues (Queues)
Loop Queues
Writeln Queues[LoopIndex]
EndLoop
See Also: NovMyPrintQueues NovUsersLoggedIn NovUsers
See Also: NovGroups NovServers
Category: Bindery Array Printer
NovPropertySecurity : Number
NovPropertySecurity is used when properties are created to determine who
can read or write the property. The number is one byte. The upper 4 bits
controls who can read the property, the lower 4 bits control who can
write to the property.
0000 Anyone
0001 Logged In
0010 Only your Object
0011 Supervisor
0100 Netware Itself
The default is $11 (00010001) which is anyone logged in can read or
write to the property.
NovPropertySecurity can also read and set the security of an existing
property.
Example:
NovPropertySecurity('MARXMENU','USERS',600) = $13
Writeln NovPropertySecurity('MARXMENU','USERS',600)
Computer Tyme * MarxMenu * Users Manual Page #198
-----------------------------------------------------------------
See Also: NovCreateProperty NovObjectSecurity NovSetProperty
Category: Bindery
NovPropertyValues (Array, Object, Prop, Type)
Reads property values of object into an array. If the property is a Set
property, then the names of the objects contained in the set are read.
If the property is an Item property, then the property is read as an
array of strings that are all 128 bytes in length. These strings will
contain binary data.
Example: ;shows contents of bindery
StandardIO
Var Objects, Obj, Prop, Ty, Values
Qualifier ObjName ObjType
NovObjects (Objects)
Loop Objects
Obj = Objects[LoopIndex].ObjName
Ty = Objects[LoopIndex].ObjType
Writeln Obj ' --------- ' Ty
NovScanProperties (Prop,Obj,Ty)
Loop Prop
Writeln ' ' Prop[LoopIndex]
NovPropertyValues(Values,Obj,Prop[LoopIndex],Ty)
Loop Values
Writeln ' ' Values[LoopIndex]
EndLoop
EndLoop
EndLoop
See Also: NovObjects NovScanProperties NovWritePropValue
Category: Bindery Array
NovReadGroups (User,Array)
This reads all the groups that User belongs to and puts them into an
array.
Example:
var Groups
NovReadGroups ('VICKI',Groups)
Loop Groups
Writeln Groups[LoopIndex]
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #199
-----------------------------------------------------------------
Category: Bindery Array
NovReadSecurityEquals (Name,Array)
This reads all the security equivalences that Name belongs to and puts
them into an array. (This includes groups).
Example:
var SecEq
NovReadSecurityEquals ('VICKI',SecEq)
Loop SecEq
Writeln SecEq[LoopIndex]
EndLoop
Category: Bindery Array
NovRemoveUserFromGroup (User,Group)
Removes a user to a group and updates GROUPS_I'M_IN, GROUP_MEMBERS, and
SECURITY_EQUALS properties. You must be supervisor equivalent in order
to use this command.
Example:
NovRemoveUserFromGroup ('MARC','EVERYONE')
See Also: NovAddUserToGroup
Category: Bindery
NovRenameObject (OldName, NewName, ObjType)
Renames an object.
Example:
NovRenameObject('VICKY','VICKI',1)
;corrects serious spelling error
Category: Bindery
NovResult : Number
NovResult is a variable like FileResult that returns the success status
of the previous Novell system call. A zero generally indicates success.
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #200
-----------------------------------------------------------------
NovScanProperties (Array, Object, ObjType)
NovScanProperties reads the properties (not the values) into an array.
You also have to pass the object type.
Novell Object Types:
1 - User
2 - Group
3 - Print Queue
4 - File Server
5 - Job Server
6 - Gateway
7 - Print Server
Example:
var Properties
NovScanProperties (Properties,NovMyLoginName,1)
Loop NumberOfElements(Properties)
Writeln(Properties[LoopIndex])
EndLoop
See Also: NovObjects NovPropertyValues
Category: Bindery Array
NovScanTrusteePaths (2D Array,ObjectName,ObjectType)
Returns a 2-dimensional array containing the name of the trustee paths
assigned to the object and the trustee access rights.
Example:
var X
NovScanTrusteePaths (X,'MARC',1)
Loop X
Writeln X[LoopIndex,1] ' ' X[LoopIndex,2]
EndLoop
Category: Novell Array
NovSecurityEquals (Security) : Boolean
Returns True if user has the security equivalent of Security.
Example:
if NovSecurityEquals ('SUPERVISOR')
Execute ('SYSCON')
endif
Computer Tyme * MarxMenu * Users Manual Page #201
-----------------------------------------------------------------
Category: Bindery
NovSemaphoreTimeout
This variable controls the amount of time (in 1/18 seconds) that
MarxMenu will wait for the value of a semaphore to become not negative.
The initial value is 50.
Example:
NovSemaphoreTimeout = 50
See Also: NovWaitOnSemaphore NovSignalSemaphore
Category: Novell
NovSemaphoreUsers (Name) : Number
This returns the number of users that have the semaphore open. This can
be used for software metering. Read file METER.INC to use this feature.
Example:
if NovSemaphoreUsers ('LOTUS') > 5
Writeln 'Sorry, all copies of LOTUS are in use.'
endif
Category: Novell
NovSemaphoreValue (Name) : Number
This returns the value of a semaphore. The value is initially set with
NovOpenSemaphore and can be adjusted with NovSignalSemaphore or
NovWaitOnSemaphore.
Example:
Writeln NamSemaphoreValue
See Also: NovOpenSemaphore NovSignalSemaphore NovWaitOnSemaphore
Category: Novell
NovSendMessage (Message,Connection)
Sends a message to the specified connection number just like the Novell
SEND command.
NovResults:
0 - Successful
252 - Buffer Full
253 - Invalid Connection Number
255 - Blocked (running CastOff)
Computer Tyme * MarxMenu * Users Manual Page #202
-----------------------------------------------------------------
See Also: NovGetMessage NovBroadcastMode
Category: Novell
NovServerLogin (On/Off)
Enables or disables logins to file server. This requires the user have
Console Operator status to use this feature.
Example:
if NovConsoleOperator then NovServerLogin Off
Category: Novell
NovServers (Array)
This command returns a string array of the file servers you are
connected to.
Example:
var Servers
NovServers(Servers)
Loop Servers
Writeln Servers[LoopIndex]
EndLoop
Category: Bindery Array
NovServerTime : Time
NovServerTime can read or set the date and time of a Novell file server.
To read the server time:
X = NovServerTime
To set the server time:
NovServerTime = X
Category: Novell Time
NovSetPreferredServer (Server)
Sets the preferred file server. Passing a '' will switch you back to the
default or primary file server.
See Also: NovSetPrimaryServer NovPreferredServer
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #203
-----------------------------------------------------------------
NovSetPrimaryServer (Server)
The primary file server is the one that executes your login scripts. It
can also be set using the NovSetPrimaryServer command.
See Also: NovSetPreferredServer NovPrimaryServer
Category: Novell
NovSetProperty (On/Off)
NovSetProperty is a variable that controls if the property to be created
is going to be a set property or an item property.
A set property contains a list of objects. An item property contains a
value up to 128 bytes long. The value can be anything.
NovSetProperty can also be used to read if a property is an item or a
set.
Example:
if NovSetProperty (Object,Property,ObjectType)
NovPropertyValues(Values,Object,Property,ObjectType)
Loop Values
Writeln Values[LoopIndex]
EndLoop
endif
See Also: NovPropertySecurity NovCreateProperty NovStaticProperty
Category: Bindery
NovShellVersion : String
Returns the Novell shell version number.
Category: Novell
NovSignalSemaphore (Name)
This increments the value of a semaphore. It is used to indicate that
you are done with a resource and makes it available for the next user.
See Also: NovOpenSemaphore NovWaitOnSemaphore
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #204
-----------------------------------------------------------------
NovStaticObject : Boolean
This variable controls if objects created will be static or dynamic
objects. Dynamic objects are deleted when the file server is rebooted.
NovStaticObject can also be used to read if an object is static or not.
Example:
Writeln NovStaticObject('MARXMENU',600) ;test for static object
See Also: NovCreateObject NovObjectSecurity
Category: Bindery
NovStaticProperty : Boolean
This variable controls if objects created will be static or dynamic
objects. Dynamic objects are deleted when the file server is rebooted.
NovStaticProperty can also be used to read if an property is static or
not.
Example:
Writeln NovStaticProperty('MARXMENU','USERS',600)
See Also: NovCreateProperty NovPropertySecurity
Category: Bindery
NovStationAddress (Connection) : String
This returns the stations internetwork address at connection.
Example:
NovStationAddress (NovConnection)
Returns the address of the user's workstation.
NovStationAddress (1)
Returns the address of station 1.
254:41 where 254 is the network number and 41 is the node number.
The second parameter (Connection) is optional. If it is left out, the
current connection is assumed.
Example:
NovStationAddress ;Returns the address of the users workstation.
Computer Tyme * MarxMenu * Users Manual Page #205
-----------------------------------------------------------------
Category: Novell
NovTotalDirSlots (Path) : Number
Returns the total number of directory slots for this volume.
Example:
Writeln NovTotalDirSlots 'SYS:'
Writeln NovTotalDirSlots 'F:'
See Also: NovFreeDirSlots
Category: Novell
NovTotalVolumeSpace (Path) : Number
Returns the total file space of the volume in bytes.
Example:
Writeln NovTotalVolumeSpace 'SYS:'
Writeln NovTotalVolumeSpace 'F:'
See Also: NovFreeVolumeSpace NovUsedVolumeSpace
Category: Novell
NovUsedVolumeSpace (Path) : Number
Returns the used volume space of Path.
Example:
Writeln NovUsedVolumeSpace('F:')
See Also: NovFreeVolumeSpace NovTotalVolumeSpace
Category: Novell
NovUserInGroup (Name,Group) : Boolean
This is used to test if other users are in a group. Returns true is the
specified user is in the specified group.
Example:
if NovUserInGroup ('KEVIN','MAILUSERS')
;do something
endif
See Also: NovInGroup
Computer Tyme * MarxMenu * Users Manual Page #206
-----------------------------------------------------------------
Category: Bindery
NovUsers (Array)
Fills array with list of all users.
Example:
var Users
NovUsers(Users)
Loop Users
Writeln Users[LoopIndex]
EndLoop
See Also: NovUsersLoggedIn NovGroups NovPrintQueues NovServers
Category: Bindery Array
NovUsersLoggedIn (Array)
Fills array with list of all users that are currently logged in.
Example:
var Users
NovUsersLoggedIn(Users)
Loop Users
Writeln Users[LoopIndex]
EndLoop
See Also: NovUsers NovGroups NovPrintQueues NovServers
Category: Novell Array
NovVersionNumber : Number
Returns the Novell Netware version number.
Category: Novell
NovVolumeNumber (Directory) : Number
Returns the Novell volume number of a directory.
Example:
Writeln NovVolumeNumber ('F:')
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #207
-----------------------------------------------------------------
NovVolumes (Array)
Reads volumes on the default server into an array.
Example:
var X
NovVolumes(X)
Loop NumberOfElements(X)
Writeln X[LoopIndex]
EndLoop
Category: Novell Array
NovWaitOnSemaphore (Name) : Boolean
This decrements the value of a semaphore and if the value is zero or
more, returns true. If the value of the semaphore is negative, it
returns false. This is used to indicate that you are out of whatever you
are testing for.
See Also: NovSignalSemaphore NovOpenSemaphore NovSemaphoreTimeout
Category: Novell
NovWritePropValue (Array,Obj,Prop,Type)
NovWritePropValue is used to write values to Item properties only and
not to static properties. Item properties contain data in 128-byte
segments. These segments are passed as an array of strings. If you are
passing binary data then build the binary data into the string array.
Any strings that have less than 128 bytes are padded with zeros.
Example:
AppendArray(Values,'123')
AppendArray(Values,'456')
AppendArray(Values,'789')
NovWritePropValue(Values,'TEST','WASTE',2)
See Also: NovPropertyValues
Category: Bindery
NumberOfElements (Array) : Number
This function returns the number of elements in the array. If the
variable is not an array, 0 is returned.
Example:
var Lines
ReadTextFile('MARXREAD.ME',Lines)
Writeln 'The file is ' NumberofElements (Lines) ' lines long.'
Computer Tyme * MarxMenu * Users Manual Page #208
-----------------------------------------------------------------
Category: Array
Now : Time
Returns the current moment or sets the system clock.
Read the current moment:
X = Now
Set the system clock:
Now = X
See Also: Today Tomorrow
Category: Time
NumericOnly (On/Off)
When NumericOnly is set to On only numbers will be accepted as input to
Readln commands.
See Also: Readln
Category: String
NumLock : Boolean
Returns true if the keyboard Num Lock light is On. This command can also
set the Num Lock On and Off.
Example:
if NumLock then Write 'NumLock is On'
NumLock On ;Turns NumLock On
NumLock Off ;Turns NumLock Off
NumLock (by itself) turns NumLock On.
To test for NumLock:
if NumLock
Writeln 'NumLock is On'
endif
See Also: CapsLock ScrollLock
Category: System
Computer Tyme * MarxMenu * Users Manual Page #209
-----------------------------------------------------------------
Offset (String) : Number
Returns the memory offset where string is located.
See Also: Segment
Category: Memory
OnKey (Char)
When char is selected, the line(s) following are executed up to the next
OnKey or end of file. This means that they are written to a BATCH file.
Example:
Onkey 'W'
cd\wordstar
ws
cd\menu
In the above example if 'W' is selected, MarxMenu will create a
temporary batch file containing all the lines under the OnKey command.
All the lines under an OnKey are written literally to the batch file
with few exceptions. All leading and trailing blanks are stripped.
String variables are evaluated and their value passed if the name of the
string variable name starts with a '%'.
If a line begins with a '|' (vertical bar), the line is interpreted
rather than written to a batch file. If a '^Label' is used under an
OnKey, a jump is made to the 'Label' and interpretation is resumed. This
is commonly used to jump to a submenu.
Another way to include MarxMenu variables and have more control inside
the batch file is to use Bat commands. Bat commands are MarxMenu
commands that create lines in the batch file you are creating.
Any OnKey statement that causes a batch file to be written to will cause
the menu to exit. MarxMenu normally will exit with ErrorLevel 0 unless
an ExitCode is set.
The first blank line under an OnKey ends what is written to the batch
file. One common mistake is that when MarxMenu commands are intermixed
with batch file statements that all the MarxMenu commands are executed
first. This is because the batch statements are written to a batch file
and executed when MarxMenu exist.
Example:
OnKey 'W'
|ChDir('c:\wordstar')
WS
|ChDir('c:\menu')
Computer Tyme * MarxMenu * Users Manual Page #210
-----------------------------------------------------------------
The above example won't work. Here's why. MarxMenu changes to the
c:\wordstar directory. Then it stores WS in a batch file buffer. Then it
changes to the c:\menu directory. Then MarxMenu writes the batch file
and exits and you are in the wrong directory.
Here is an example of using conditional statements under an OnKey
command:
Example:
OnKey 'S'
|if DisplayType = 'HERCMONO'
|ChDir('C:\MONSMART')
SMART
|else
|ChDir('C:\COLSMART')
SMART
|endif
In the above example MarxMenu tests to see if a color-compatible screen
is available. If so it runs SMART out of the color directory. Otherwise
it runs SMART out of the mono directory. Note that all commands that
MarxMenu sees start with the vertical bar character.
Sometimes you want to execute a command where the command is created by
a complex set of rules. The BAT command is useful here.
Example:
OnKey 'P'
|Bat 'CAPTURE Q=' + Queue + ' C=1 NB NFF TI=5 Local=' + PrnPort
In this example the |Bat command allows more specific control over
what is sent to the batch file for execution.
See Also: MxCmd Bat UseArrows OnScreenOnly
Category: Conditional
OnScreenOnly (On/Off)
This allows you to restrict selections to only what is actually on the
screen. Hidden OnKey commands will not execute if this is set on. This
allows you to limit user selection to the choices on the screen.
Example:
OnScreenOnly On
See Also: OnKey
Computer Tyme * MarxMenu * Users Manual Page #211
-----------------------------------------------------------------
Category: Conditional
OpenPrinter
This command opens the printer device. It is not necessary to use this
command since that it is done automatically whenever you print. But, if
you are running under a multitasking shell like Windows or DesqView, it
will reserve the printer for your task.
If the printer is locked, or if you have specified a file name that
can't be created, the variable FileResult will contain the DOS error
code (usually 5 for access denied). A FileResult of 0 indicates success.
See Also: ClosePrinter FileResult PrinterName
Category: Printer
OptionSwitch (String1,String2) : Boolean
This command tests if String1 contains the option switch String2. If it
does, it will remove the switch from String1.
Example:
String1 = 'Test /A/B/C'
HasB = OptionSwitch(String1,'B')
HasB will be true.
String1 will contain 'Test /A/C'
Category: String
Or : Operator
Returns logical Or if operators are boolean; or bitwise Or if operators
are numeric.
Example:
if (B < 9) or (C > 5) then ..... ;boolean or
X or $0F ;bitwise or
See Also: And Xor Not
Category: Math Boolean
Computer Tyme * MarxMenu * Users Manual Page #212
-----------------------------------------------------------------
Ord (Char) : Number
Returns the numeric value of an ascii character.
Example:
Ord('A') ;returns 65
Char(Ord('A') + 1) ;returns 'B'
See Also: Char
Category: String
OutFile : String
When using StandardIO the input and output files by default use the
console. The output can be overridden by setting InFile to point to a
different file or device.
Example:
OutFile = 'OUTPUT.TXT'
StandardIO
See Also: InFile StandardIO
Category: File
OverKey : String
When using UseArrows, OverKey returns the character that selects the
item that the inverse bar is over.
This can be used with IdleProgram to display context sensitive help as
you move the inverse bar over different selections.
See Also: IdleProgram
Category: String
OverLay (MenuName)
Overlay loads another menu as if that menu were a procedure of the
current menu. After the overlaid menu exits, control is returned to the
calling menu at the next line after the overlay command.
Like the Chain command, Overlay is very fast and doesn't require
MarxMenu to be reloaded.
Example:
Overlay 'SUBMENU'
Computer Tyme * MarxMenu * Users Manual Page #213
-----------------------------------------------------------------
When using overlays, all variables declared as shared are accessible to
the main program and all overlays. The shared variables have to be the
same for all overlays.
See Also: Shared Chain
Category: Execution
Overlayed : Boolean
Overalyed returns true if menu is loaded as an overlay.
Category: Execution
PadLeft (String,Length) : String
PadLeft will return String filled with blanks on the left side so that
the length of the string is Length.
Example:
Writeln PadLeft('123',5) ;returns ' 123'
See Also: PadRight
Category: String
PadRight (String,Length) : String
PadRight will return String filled with blanks on the right side so that
the length of the string is Length.
Example:
Writeln PadRight('123',5) ;returns '123 '
See Also: PadLeft
Category: String
ParallelPorts : Number
Returns number of parallel ports.
Category: System
Computer Tyme * MarxMenu * Users Manual Page #214
-----------------------------------------------------------------
ParamStr (Num) : String
Returns the DOS parameter string from the command line. The 0 parameter
is MARXMENU.EXE. The 1 parameter is the name of the menu file you are
using. This is like the %1 %2 %3 ... in batch file parameters.
Category: String
ParentEnvironment
ParentEnvironment selects the parent environment for use with
environment access commands.
See Also: ReadEnv SetEnv ReadEnvironment ShellEnvironment
See Also: CurrentEnvironment MasterEnvironment
Category: Environment
Password (Pswd,column,row)
This command opens up a password box at row and column. The user must
type the password correctly before the command will execute.
Example:
OnKey 'X'
|PassWord('shell',4,3)
COMMAND.COM
The password is case sensitive if the password in the source code is
lower case. But if the password in the source code is in uppercase then
the password is not case sensitive.
Example:
Password 'CRITTER' 4 3 ;will accept critter or CRITTER
Password 'CriTTeR' 4 3 ;will only accept CriTTeR
Category: Conditional
PathPart (String) : String
Returns the path part of a filename.
Example:
PathPart ('C:\MARX\MARXMENU.EXE') ;returns C:\MARX
See Also: Extension NamePart FilePart
Category: String
Computer Tyme * MarxMenu * Users Manual Page #215
-----------------------------------------------------------------
PauseAfterExecute (On/Off)
If on, this command causes the message "Press any key to return to
MarxMenu..." to appear after an execute command is executed.
See Also: Execute
Category: Execution
PcType : String
PcType returns the type of computer you are running as a string.
Types: PC, XT, AT, PS2.
Category: System
Pi : Real
Returns the value of Pi to 18 digits.
Category: Math Float
PickFile (FileSpec,column,row,height) : String
Allows you to display a directory of files on the screen from a menu.
Normally used to display a list of files for the user to choose from.
Could be used in a command to load a word processor or database. Allows
selection of the file to be loaded by the word processor or database
program. The filename can be passed to a percent variable placed in the
batch file executing the application. See example files on MarxMenu
distribution disk.
Example:
FileName = PickFile('C:\WORDSTAR\*.DOC',3,4,17)
Notice: The use of a variable with a name that starts with a '%' allows
the choice to be passed to a batch file for execution.
The three numbers represent the column and row of the upper left corner
of the box and the height of the box. All DrawBox commands can be used
here to control the looks of the PickFile window. This includes the
BoxHeader command.
Category: String
Computer Tyme * MarxMenu * Users Manual Page #216
-----------------------------------------------------------------
PickMany(SourceArray,DestinationArray)
PickMany displays a string array in the current window and allows you to
choose as many lines as you want. The chosen lines go into
DestinationArray.
When the window appears, the space bar toggles the marked status of the
line. The right arrow sets the marked status and the left arrow resets
the marked status. Ctrl-Right-Arrow marks all lines, Ctrl-Left-Arrow
unmarks all lines. The return key accepts the selection and exits. The
ESC key aborts.
If using a mouse, the left button toggles the mark on the current line.
The right button accepts and exits.
If no selections are made by marking selections then pressing Return on
an entry selects the item the cursor bar is over. If ESC is pressed,
the DestinationArray is left unchanged. You can test LastKey to see what
was pressed.
Example:
;PICK&DEL.MNU Usage "MARXMENU PICK&DEL mask"
;
var temp,work,hitlist
boxheader "PICK&DEL: A MarxMenu Demo"
boxfooter "Space=Mark, <Enter>=DoIt"
drawbox 25,5,30,15
readdirectory(cmdline,work) ;Read Dir into Array work
pickmany(work,hitlist) ;Use PickMany to select files!
boxheader "Deleting Files"
drawbox 20,10,40,4
loop hitlist
writeln " Now Deleting File: " hitlist[loopindex]
delfile hitlist[loopindex]
wait (10)
endloop
erasetopwindow
erasetopwindow
See Also: PickManyPositions PickOne
Category: String Array
Computer Tyme * MarxMenu * Users Manual Page #217
-----------------------------------------------------------------
PickManyPositions (Array)
After running PickMany an array PickManyPositions is created that has
the position numbers in the original array that were chosen.
See Also: PickMany
Category: String Array
PickOne (Array) : String
This command displays an array in the current window and lets you pick a
line and returns the chosen line.
Example:
var BatFiles, BatName
ReadDirectory('*.BAT',BatFiles)
DrawBox 35 10 20 9
BatName = PickOne(BatFiles)
See Also: PickMany PickPosition
Category: String Array
PickPosition : Number
The variable PickPosition works with the PickOne command. PickPosition
returns the number of which element in the array was picked.
See Also: PickOne
Category: String Array
Port (Number) : Number
Returns the value at the port or writes a number to a port.
Example:
X = Port(20) ;Reads port 20 into X
Port(20) = X ;Writes X to Port 20
Category: Memory
Computer Tyme * MarxMenu * Users Manual Page #218
-----------------------------------------------------------------
Pos (substring,string) : Number
Finds position of substring in string. If substring isn't found, Pos
returns 0.
Example:
pos('CD','ABCDE') returns 3
Category: String
PosInList (String,Array) : Number
Scans a string array looking for a match on string and returns the array
index of the first matched string if found or a zero if not found.
Example:
X[1] = 'JOE'
X[2] = 'KEVIN'
X[3] = 'MARC'
Writeln PosInList('KEVIN',X) ;returns 2
See Also: PosInSortedList
Category: Array
PosInSortedList (String,Array) : Number
Scans a string array looking for a match on string in a sorted array and
returns the array index of the first matched string if found or a zero
if not found. The array must be in sorted order. A binary search is used
to make this command very fast.
Example:
X[1] = 'JOE'
X[2] = 'KEVIN'
X[3] = 'MARC'
SortArray (X)
Writeln PosInList('KEVIN',X) ;returns 2
See Also: PosInList
Category: Array
Computer Tyme * MarxMenu * Users Manual Page #219
-----------------------------------------------------------------
Power (Real,Real) : Real
Raises a real to a given power.
Example:
Power(3,4) ;returns 81.0
Category: Math Float
Pred (Number) : Number
Returns number minus 1.
Example:
Pred(5) ;returns 4
See Also: Succ
Category: Math
Print (String)
Prints string to the printer with no CR or LF. If there is an error
printing, the error is returned in FileResult.
Example:
Print Char(12) ;prints a form feed
Category: Printer
PrinterName (String)
Sets the filename for the printer to use. The default name is PRN.
Other common printer names include: LPT1, LPT2, LPT3, and AUX. You can
also use filenames to direct printer output to a file.
See Also: ClosePrinter OpenPrinter
Category: Printer
Println (String)
Prints string to the printer with CR and LF.
See Also: Print
Category: Printer
Computer Tyme * MarxMenu * Users Manual Page #220
-----------------------------------------------------------------
PrintScreen (On/Off)
Turns the print screen function On and Off. Turning the print screen off
disables the print screen key. This can be used to prevent a computer
from locking up when the user hits the Print Screen key with no printer
attached.
Example:
PrintScreen Off
Category: Printer
Procedure (name)
This word begins the definition of a procedure. A procedure is like a
subroutine. Once the procedure is defined, all you have to do to call
the procedure is use its name. The procedure definition is terminated by
the command EndProc.
Example:
Procedure SelectFile
BoxHeaderColor ForeColor BackColor
BoxBorderColor Cyan Mag
BoxInsideColor Yellow Mag
InverseColor Yellow Red
Return PickFile (FileType,4,5,17)
EndProc
Whenever we use the word SelectFile in the menu, all the lines of the
procedure SelectFile will execute.
Parameters can be passed to procedures. When a parameter is passed it is
normally passed by value. This mean that a copy of the original is
passed. Whatever you do to the copy doesn't affect the original value.
Example:
var A
Procedure Square (X)
X = X * X
Writeln X
EndProc
A = 6
Square (A) ;prints 36
Writeln A ;prints 6
In the above example Square (A) will write 36 but Writeln A will write
6. The reason is that Square passes a copy of A to X but the value of X
is not returned to A. If you want the original A to be affected you
would use the Loc command.
Computer Tyme * MarxMenu * Users Manual Page #221
-----------------------------------------------------------------
A = 6
Square (Loc A) ;prints 36
Writeln A ;prints 36
In this example we pass Loc A to the Square procedure. Thus, instead of X
being set to 6, X is set to point to A. As a pointer, any operation
performed on X is performed on A instead.
You can also return parameters from procedures using the Return command.
Example:
Procedure Cube (X)
Return X * X * X
EndProc
Writeln Cube(3) ;returns 27
In MarxMenu you can return any number of parameters as long as the
calling procedure is expecting the same number of parameters.
Example:
Procedure CenterOfScreen
Return (ScreenWidth / 2) (ScreenHeight / 2)
EndProc
GotoXY(CenterOfScreen)
In the above example, GotoXY expects two parameters. CenterOfScreen
returns two parameters so MarxMenu is happy with it.
See Also: EndProc Return Loc
Category: Misc
PullMenu (On/Off)
Controls the behavior of the left and right arrow keys when using
pull-down menus. Default is Off. See PULL.MNU for example.
Category: Display
Qualifier
Used to create qualifiers which are named elements of an array.
Example:
Var President
Qualifier FirstName, LastName
Computer Tyme * MarxMenu * Users Manual Page #222
-----------------------------------------------------------------
President.FirstName = 'George'
President.LastName = 'Washington'
See Also: Var Constant Shared
Category: Variable
QualVal (Qualifier) : Number
Returns the numeric value of a qualifier.
Example:
Qualifier A B C
Writeln QualVal C ;returns 3
See Also: Qualifier
Category: Variable
Random : Number
The Random command returns random numbers between 0 and +2,147,483,647.
(2^31). The algorithm has been checked for good uniformity and takes
advantage of re-seeding itself from random events like the timer
interrupt and keyboard input.
To get a random number in a specific range, use the Mod command.
Example:
Write 'Pick a Number from 1 to 10 '
Writeln (Random mod 10 + 1)
Category: Math
ReadAscTextFile (FileName,2D Array)
ReadAscTextFile reads a standard comma delimited text file into a
2-dimensional array. The lines of the file must be limited to 1000
characters and the number of lines must be less than 13100. It also has
to fit in memory.
All text in quotes is converted to strings. Numbers not in quotes are
translated as numbers unless there is a '.' in which case they are
translated as floating point numbers.
See Also: ReadlnAsc
Category: File Array
Computer Tyme * MarxMenu * Users Manual Page #223
-----------------------------------------------------------------
ReadDirectory (Path,Array)
Reads a directory into an array. This command is controlled by several
variables that control its behavior.
If WholeFileNames is set to true, the names that are returned contain
the whole path. If HiddenAndSystem is set to true, then Hidden and
System files are also read. If IncludeDirectories is set to true, then
directories are also read.
If DirectoriesOnly is set to true, then only directory names are read.
Example:
Var X
WholeFileNames Off
ReadDirectory('*.MNU',X)
Loop X
Execute ('COPY ' + X[LoopIndex] + ' A:')
EndLoop
Here's a recursive example where we use ReadDirectory to read all the
directories on the current drive.
StandardIO
DirectoriesOnly
WholeFileNames
ReadSubdirectories(CleanFileName('\'))
Procedure ReadSubdirectories (Dir)
var Subs
Writeln Dir
ReadDirectory(Dir,Subs)
Loop Subs
ReadSubdirectories(Subs[LoopIndex])
EndLoop
EndProc
See Also: WholeFileNames HiddenAndSystem IncludeDirectories
See Also: DirectoriesOnly ReadSqDirectory
Category: Array Directory
Computer Tyme * MarxMenu * Users Manual Page #224
-----------------------------------------------------------------
ReadEnv (String) : String
Returns the environment string specified.
Example:
PathString = ReadEnv('PATH')
You can also read environment strings by enclosing the environment
variable name in '%' like you do in batch files.
Example:
PathString = %PATH%
See Also: SetEnv ReadEnvironment ShellEnvironment
See Also: CurrentEnvironment ParentEnvironment MasterEnvironment
Category: Environment
ReadEnvironment (Array)
Reads all environment variables into an array. The variable LongestLine
is set to the length of the longest environment variable.
Example:
Var Env
ReadEnvironment (Env)
Writeln 'Your current environment variables are:'
Loop Env
Writeln Env[LoopIndex]
EndLoop
Writeln
Writeln('Your Environment Size is ',Str(EnvSize))
Writeln('You are using ',Str(EnvSize-EnvFree),' bytes.')
Writeln('You have ',Str(EnvFree),' bytes free.')
See Also: SetEnv ReadEnv ShellEnvironment
See Also: CurrentEnvironment ParentEnvironment MasterEnvironment
Category: Environment Array
ReadFileBlock (Name,Offset,Size,Segment)
ReadFileBlock reads disk file Name starting at byte Offset for Size
bytes into memory buffer Segment. It is intended to read any kind of
file.
The maximum value for Size is 65504. The segment must be as large as the
number of bytes you are reading. The following example will copy a small
file.
Computer Tyme * MarxMenu * Users Manual Page #225
-----------------------------------------------------------------
Example:
Var RamBlock Size
Size = FileSize 'MARXREAD.ME'
RamBlock = GetMem(Size)
ReadFileBlock('MARXREAD.ME' 0 Size RamBlock)
WriteFileBlock('COPYREAD.ME' 0 Size RamBlock)
FreeMem(RamBlock)
See Also: WriteFileBlock GetMem FreeMem
Category: File Memory
ReadKey : String
Returns the character that is input from the keyboard. If UseArrows is
on then the inverse bar will appear in the current window for selecting
a choice.
Example:
Var Key
Repeat
Writeln( 'Press the <ESC> key to exit this program.' )
Key = ReadKey
Until Key = Esc
See Also: UseArrows UpperCaseOnly
Category: Keyboard
Readln : String
Reads a string from the keyboard. By default the size of the string is
from the cursor position to one space left of the right side of the
current window. The size can be set to a smaller value using the
InputLength command.
InputString can be set to preload the string with a value for editing.
UppercaseOnly can be set to force the string be entered in uppercase.
Example:
Name = Readln
Number = Value (Readln) ;Converts to an numerical value
State = UpperCase (ReadLn)
See Also: InputString UpperCaseOnly InsertMode InputLength
See Also: TrimInputString InputBlankChar CapsOnly Security
See Also: NumericOnly CapFirstChar FullLineReturn
Computer Tyme * MarxMenu * Users Manual Page #226
-----------------------------------------------------------------
Category: Keyboard String
ReadlnAsc (File,Array)
ReadlnAsc reads a single line from a comma delimited Ascii file and
breaks the fields out into an array.
All fields in quotes are considered strings. If the field is just comma
delimited and numeric then it is converted to a number. If it has a
decimal point then it is converted to a real number.
Example:
var F Fields
FileAssign(F,'TEST.ASC')
FileOpen(F)
while not EndOfFile(F)
ReadlnAsc(F,Fields)
loop Fields
Write Fields[LoopIndex] ' '
endloop
Writeln
EndWhile
See Also: ReadAscTextFile
Category: File
ReadSqDirectory (Path,2DArray)
ReadSqDirectory works like ReadDirectory but rather than just returning
the file name it returns all the information about the file in a 2
dimensional array. The fields of the array are as follows:
1 - Name
2 - Date last Updated
3 - Size
4 - Attributes
Under Netware there are several other fields:
5 - Date Created
6 - Date last Accessed
7 - Date last Archived
8 - Owner
9 - Maximum Rights Mask (Directories)
Example:
Var X Y
ReadSqDirectory('*.EXE',X)
Writeln 'Listing File Name, Date Last Accessed, and Size.'
Loop X
Y = LoopIndex
Writeln X[Y,1] ' ' DateString(X[Y,6]) ' ' X[Y,3]
EndLoop
Computer Tyme * MarxMenu * Users Manual Page #227
-----------------------------------------------------------------
See Also: WholeFileNames HiddenAndSystem IncludeDirectories
See Also: DirectoriesOnly ReadDirectory
Category: Array Directory
ReadTextFile (FileName,Array)
This command reads a text file into a string array. It also sets the
variable LongestLine to the length of the longest line in the file.
Example:
Var Docs
ReadTextFile('MARXMENU.DOC',Docs)
;After the read, Docs[1] becomes the first line of the file.
;Docs[NumberOfElements(Docs)] becomes the last line.
Loop NumberOfElements(Docs)
; Convert each line to its uppercase equivalent
Docs[LoopIndex] = UpperCase Docs[LoopIndex]
EndLoop
;Save the newly formatted array
WriteTextFile ('NEWMM.DOC',Docs)
Do not use FileOpen with ReadTextFile.
The power of the ReadTextFile and WriteTextFile have expanded. You can
now load and save arrays of any variable types, multidimensional arrays,
and mixed array types. This includes strings, numbers, and booleans.
File variables are also stored. When a file variable is stored and
reloaded the FileAssign command is not necessary.
See Also: LongestLine
Category: File Array
Real (Integer) : Real
Returns the real equivalent of an integer.
Example:
Real(5) ;returns 5.0
See Also: Integer
Category: Math Float
Computer Tyme * MarxMenu * Users Manual Page #228
-----------------------------------------------------------------
Reboot
Causes the computer to do a warm reboot.
See Also: ColdBoot
Category: Execution
ReleaseDate : String
Returns the MarxMenu Release Date.
Category: String
Repeat
Used for program control. Usage:
REPEAT
(statement)
(statement)
UNTIL (condition)
Example:
Var Key
Repeat
Key = ReadKey
If Key = 'A'
Bat( 'DOLIST.EXE' )
ExitMenu
EndIf
If Key = F1 Then Help
Until Key = Esc
Category: Conditional
ResizeWindow (Horizontal Vertical)
Changes the size of the top window. The horizontal and vertical numbers
are added to the current size. Use negative numbers to shrink the
window. The top left corner stays in the same place.
Example:
DrawBox 15 5 30 15
ResizeWindow 15 5
See Also: MoveWindow
Computer Tyme * MarxMenu * Users Manual Page #229
-----------------------------------------------------------------
Category: Display
Return (param,param,...)
Exits a procedure and optionally returns parameters to the calling
procedure. It can return as many parameters as you want as long as the
calling program uses the same number of parameters. Otherwise, you will
get an "Invalid number of parameters" error.
Example:
Procedure SmallRandomNumber
{Returns a random number between 1 and 100}
var SmallRand
SmallRand = Random mod 100
Return (SmallRand + 1)
EndProc
See Also: Procedure EndProc
Category: Misc
ReturnCode : Number
When you use the Execute function, a ReturnCode value is fed into this
variable when you return to the menu. The code returned is the same as
what the DOS ErrorLevel would be. This will not work if you use the
UseCommand On function because COMMAND.COM would have been loaded and
the returncode would be lost.
You also have to specify the COM or EXE extension or else MarxMenu will
use COMMAND.COM and the return code will be lost.
Example:
Execute 'INMEM.EXE SK'
if ReturnCode = 0 then Writeln 'Sidekick not Loaded!'
See Also: ExitCode
Category: Execution
Right (string,count) : String
Returns right characters of string for length count.
Example:
Right('ABCDEF',3) returns 'DEF'
Category: String
Computer Tyme * MarxMenu * Users Manual Page #230
-----------------------------------------------------------------
RmDir (String)
Removes a directory. The FileResult variable returns the DOS result
error code. A zero in FileResult indicates success. You can't remove a
directory that contains files or other directories.
Example:
RmDir 'C:\NETUTILS'
See Also: ChDir MkDir
Category: Directory
RollWindow (Number)
Windows can be looked at as a stack. RollWindow will roll a previous
window to the top of the stack making the previous window the current
window.
Example:
;Make the third window on the stack the active window
RollWindow 3
;Write out message
Writeln 'You have mail waiting!'
;Now put the windows back
PushBackWindow (3)
Procedure PushBackWindow (N)
;Will roll a window back to its original position on the stack
;The parameter should be the same as the parameter for the call
;to RollWindow. If you use RollWindow(3) then use PushBackWindow(3)
Loop N
RollWindow N
EndLoop
EndProc ;PushBackWindow
See Also: CurrentWindow SetTopWindow
Category: Display
Run variable (parameters)
This runs a procedure that was stored in a variable.
Example:
var Y
Computer Tyme * MarxMenu * Users Manual Page #231
-----------------------------------------------------------------
Procedure WriteSquared (X)
Writeln (X * X)
EndProc
Y = Loc WriteSquared
Run Y(3) ; This will write a 9 on the screen
Warning! Don't put the variable you are running in parentheses.
Run (Y,3) ; this won't work
See Also: Loc
Category: Misc
SavePosition (On/Off)
If SavePosition is On, MarxMenu will return to the last menu selection
you made when MarxMenu is re-entered. As you select menu layers your
keystrokes are stored in an internal string variable called KeySave. On
exit, MarxMenu writes KeySave to an environment variable KSV. On return
to MarxMenu, this variable is retrieved. The return point may be altered
by using the command KeySave = (String).
Another thing this points out is that environment variables can be used
to store information and allow MarxMenu to remember things from one
selection to another. Since MarxMenu doesn't stay memory resident, this
is the only way I have found to store information.
Category: Keyboard Environment
ScreenHeight : Number
Returns number of rows of character on your screen. Normally this is 25.
Category: Video
ScreenWidth : Number
Returns number of columns of character on your screen. Normally this is
80.
Category: Video
Computer Tyme * MarxMenu * Users Manual Page #232
-----------------------------------------------------------------
ScrollLock : Boolean
Returns true if Scroll Lock is on. This command can also set the Scroll
Lock on and off.
Example:
if ScrollLock then Write 'ScrollLock is On'
ScrollLock On ;Turns ScrollLock On
ScrollLock Off ;Turns ScrollLock Off
ScrollLock (by itself) turns ScrollLock On.
To test for ScrollLock:
if ScrollLock
<do something>
endif
See Also: CapsLock NumLock
Category: System
ScrollMove (On/Off)
This allows you to control whether or not the ScrollLock will allow you
to move the top window. Default is On.
Example:
ScrollMove Off
Category: Display
Second : Number
Returns the current second.
Category: Time
SecondOf (Date) : Number
Returns the second of a date. If Date is passed as a string it is
converted automatically.
Example:
SecondOf '6:32:23' ;returns 23
See Also: TimeOf BadDate
Computer Tyme * MarxMenu * Users Manual Page #233
-----------------------------------------------------------------
Category: Time
Security (On/Off)
When security is on, Readln echos '*' instead of the letters that are
being typed. This is used for such things as entering passwords other
than using the password command.
Example:
Security On
See Also: Readln
Category: String
Segment (String) : Number
Returns the memory segment where string is located.
See Also: Offset
Category: Memory
SelectPath : String
This command uses another program in the Computer Tyme DOS TOOLBOX
called Pick Directory to read a text into a variable. You must have
Computer Tyme Pick Directory for this feature to work.
Example:
OnKey 'B'
|%BackPath = SelectPath
cd %BackPath
backup c: a:
Category: Directory
SerialNumber
This returns your MarxMenu serial number in a numeric variable. If you
are using an unregistered evaluation version of MarxMenu the result is
(0)-Zero.
Example:
if SerialNumber <> 0
writeln "My MarxMenu serial number is: " SerialNumber
else
writeln "This is an unregistered MarxMenu, no serial number."
endif
Computer Tyme * MarxMenu * Users Manual Page #234
-----------------------------------------------------------------
SerialPorts : Number
Returns number of serial ports.
Category: System
Set [Value,Value,Value,Value]
Set is used to define an array made up of specific values.
Example:
X = Set[2,3,5,7] ;Variable X becomes an array containing 2 3 5 and 7.
Category: Array
SetArraySize (Array,Size)
If the array is larger than Size the array is truncated. If it is
smaller, memory is allocated for the array.
Category: Array
SetEnv (String)
This is used to set environment strings. It can be used on the Current,
Parent, Master or Shell environment.
Example:
SetEnv ('PATH=C:\')
SetEnv ('COMSPEC=X:COMMAND.COM')
You can also set the environment by using '%' on each side of the
environment variable.
Example:
%PATH% = 'C:\'
%COMSPEC% = 'O:\COMMAND.COM'
MarxMenu also allows you to select which environment you are working
with. This is done with the following commands.
CurrentEnvironment
ParentEnvironment
MasterEnvironment
ShellEnvironment (default)
See Also: ReadEnv ReadEnvironment ShellEnvironment
See Also: CurrentEnvironment ParentEnvironment MasterEnvironment
Computer Tyme * MarxMenu * Users Manual Page #235
-----------------------------------------------------------------
Category: Environment
SetTimerTask (Loc Procedure,Ticks)
SetTimerTask allows for background multitasking or real time events. The
Ticks parameter specifies how often the task will run in clock ticks
(18.2 times a second). If 6 ticks are specified then the task will run
every 6 clock ticks or about 3 times a second. This command can be used
to run scheduled events as well as periodic events.
Example:
SetTimerTask(Loc BlinkColor,9)
Procedure BlinkColor
gotoxy 5 5
textcolor white (random mod 7)+1
writeln " * Colors Change * "
EndProc
Category: Event
SetTopWindow (Number)
Selects a window by number making it the current window and moves it to
the top.
Example:
DrawBox ....
ThisWindow = CurrentWindow
DrawBox ....
DrawBox ....
SetTopWindow (ThisWindow)
See Also: CurrentWindow RollWindow SetWindowUnder
Category: Display
SetWindowUnder (Window1,Window2)
This command moves Window1 underneath Window2. This can be used to put a
window back in the stack after you use SetTopWindow.
Example:
SetWindowUnder (StatusWindow,StatusWindow + 1)
See Also: CurrentWindow SetTopWindow RollWindow
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #236
-----------------------------------------------------------------
Shadow (On/Off)
Turn window shadows On/Off.
Example:
Shadow On
Category: Display
ShadowColor (Foreground,Background)
Sets the color of the shadow. There are actually two shadow colors.
MarxMenu stores different values for big shadows and small shadows.
See Also: BigShadow SmallShadow ShadowPosition Shadow
Category: Color
ShadowPosition (Number)
Selects the shadow position around the window. A zero (default) sets the
shadow position to the bottom right side. A one sets the shadow position
to the bottom left. Using ShadowPosition turns shadowing on so a Shadow
On command is not required.
Example:
ShadowPosition 1
See Also: Shadow ShadowColor BigShadow SmallShadow
Category: Display
Shared
The key word SHARED can be used to define variables just like VAR. Any
variable defined with SHARED is passed globally to and from overlays.
The important thing is that the Shared variables must be defined exactly
the same way between the overlays. There is also a predefined variable
called COMMON. Technically, Shared variables are qualifiers off of
COMMON.
Example:
Shared Var1 Var2 Var3
See Also: Var Constant Qualifier
Category: Variable
Computer Tyme * MarxMenu * Users Manual Page #237
-----------------------------------------------------------------
ShellEnvironment
ShellEnvironment selects the environment of the last COMMAND.COM in
memory for use with environment access commands. This is usually the
same as the Master Environment.
More than one COMMAND.COM is loaded when you are running a shell under
Windows or DesqView. When using these programs, you will want to access
the Shell Environment instead of the Master Environment. The Shell
Environment is the one that will run batch files.
See Also: ReadEnv SetEnv ReadEnvironment MasterEnvironment
See Also: CurrentEnvironment ParentEnvironment
Category: Environment
Shl : Operator
Shift left, does a binary 32 bit shift left.
Example:
Writeln 5 Shl 2 ;returns 20
See Also: Shr
Category: Math
Shr : Operator
Shift right, does a binary 32 bit shift right.
Example:
Writeln 20 Shr 2 ;returns 5
See Also: Shl
Category: Math
Sin (Radians) : Real
Returns the Sine of a real.
Category: Math Float
Computer Tyme * MarxMenu * Users Manual Page #238
-----------------------------------------------------------------
SingleLineBox
Selects single line box for menu borders.
See Also: DoubleLineBox BlockBox CustomBox NoBoxBorder
Category: Display
SmallShadow
Selects small shadow type.
See Also: BigShadow ShadowPosition ShadowColor
Category: Display
SortArray (Array)
SortArray will do an alphabetical sort on an array of strings.
Example:
Sort a Text File:
Usage: DIR|MARXMENU SORT|MORE
MARXMENU SORT INFILE OUTFILE
SORT.MNU
var SortBuf
StandardIO
ReadTextFile (ParamStr(2),SortBuf)
SortArray(SortBuf)
WriteTextFile (ParamStr(3),SortBuf)
Category: Array
SortArrayLinked Array,KeyArray
SortArrayLinked will sort an array based upon the contents of a key
array.
Example:
var NumberArray,key
writeln "Array sequential on element 1"
loop 10
NumberArray[loopindex,1]=loopindex
NumberArray[loopindex,2]=(random mod 50 + 1)
writeln NumberArray[loopindex,1] " " NumberArray[loopindex,2]
endloop
Computer Tyme * MarxMenu * Users Manual Page #239
-----------------------------------------------------------------
MatrixInvert NumberArray
key = NumberArray[2]
matrixinvert NumberArray
sortarraylinked NumberArray,key
writeln "Array now sorted based on element 2"
loop 10
writeln NumberArray[loopindex,1] " " NumberArray[loopindex,2]
endloop
See Also: MatrixInvert
Category: Array
Sound (On/Off)
Turn sound effects On/Off.
Category: Display
SplitPath (Array)
SplitPath reads the PATH environment variable and splits it up into an
array of strings that are directories the path is made up of. All
directory names are capitalized.
Example:
var P
SplitPath P
Loop P
Writeln P[LoopIndex] ;writes the directories in PATH
EndLoop
See Also: BuildPath FixPath
Category: String Array Environment
SpxFreeConnections : Number
Returns the number of free SPX connections.
Category: Novell
Computer Tyme * MarxMenu * Users Manual Page #240
-----------------------------------------------------------------
IpxLoaded : Boolean
Returns True if SPX is loaded
Category: Novell
SpxMaxConnections : Number
Returns the maximum number of SPX connections allowed.
Category: Novell
Sqr (Real) : Real
Returns the Square Root of a real.
Category: Math Float
StandardIO (On/Off)
This tells MarxMenu to use standard Input and Output file handles for
reading the keyboard and writing to the screen when turned On. When
turned Off, MarxMenu does direct screen writes. When StandardIO is on,
several MarxMenu commands will send ANSI escape sequences. The commands
that send ANSI sequences are as follows:
TextColor
TextBackground
ClearScreen
ClearLine
GotoXY
The input and output can be redirected by using the InFile and OutFile
variables.
See Also: InFile OutFile
Category: Display Ansi
Str (Number) : String
Returns a string value from a numeric variable.
Example:
writeln "*"+Str(6 * 5)+"*" ;returns the string '*30*'
See Also: Value
Computer Tyme * MarxMenu * Users Manual Page #241
-----------------------------------------------------------------
Category: String
StuffAKey (String or Number)
Stuffs a single key into the DOS keyboard buffer when MarxMenu exits.
The limit is 16 characters.
Example:
StuffAKey($3F00) ;stuff the F5 key
StuffAKey F5 ;same thing
Do not mix StuffAKey with StuffKBD. Use one or the other.
Category: Execution Keyboard String
StuffKBD (String)
Stuffs the string into the DOS keyboard buffer when MarxMenu exits. The
limit is 16 characters.
Example:
StuffKBD 'LOGOUT' + CR
Category: Execution Keyboard String
StuffKeyboardNow
Normally the keyboard stuffing is done as MarxMenu quits. This forces
the keyboard to be stuffed immediately.
Category: Keyboard
Succ (Number) : Number
Returns number plus 1.
Example:
Succ(4) ;returns 5
See Also: Pred
Category: Math
Computer Tyme * MarxMenu * Users Manual Page #242
-----------------------------------------------------------------
Suggest (Char)
Normally the UseArrows command will start in the upper left-hand corner.
By using the Suggest command, you can set it to start on any menu
selection.
Example:
Suggest 'E'
Category: Display
TaskNumber : Number
Reads the current task number. If running DesqView or Software Carousel,
this is set to the window number. If running TaskMax this is set to the
TaskID. If running in a DOS session under Windows it is set to the
virtual machine number It can also be set by setting the TASK=
environment variable.
The TaskNumber is used to create unique batch files in an operating
environment that supports multiple tasks so that temporary files from
one task don't trash temporary files from another task when running
MarxMenu more than once.
Category: System
TextBackground (color)
Sets text background color.
Example:
TextBackground Blue
Category: Color Ansi
TextColor (Foreground,Background)
Sets the color of text to be displayed on the screen. TextColor resets
the value of CapsColor.
Example:
loop 16
TextColor loopindex,Brown
Writeln "This is a test"
endloop
Category: Color Ansi
Computer Tyme * MarxMenu * Users Manual Page #243
-----------------------------------------------------------------
TextMode (num)
Sets the video text mode.
0 = 40 column BW
1 = 40 column COLOR
2 = 80 column BW
3 = 80 column COLOR
7 = Mono
258 = 43/50 line EGA BW
259 = 43/50 line EGA COLOR
Example:
TextMode BW80
Category: Video
TextPos : Number
TextPos returns the current position in a text file. This can be saved
so that you can go to the same place using TextSeek.
See Also: TextSeek
Category: File
TextSeek (Number)
TextSeek moves to a specific byte in a text file.
See Also: TextPos
Category: File
Then
Conditional control.
Example:
if <condition> then <do something>
See Also: If Else Endif ElseIf
Category: Conditional
Computer Tyme * MarxMenu * Users Manual Page #244
-----------------------------------------------------------------
TimeOf (String) : Number
Converts a string representing a date to a time number. The number is
the number of seconds since 01-01-80. Conversion follows international
rules based on the country code.
Examples:
'4-7-91' ;04-07-1991 00:00:00
'April 7th, 1991 4:35pm' ;04-07-1991 16:35:00
'12:35:23a' ;04-07-1991 00:35:23
'3:15' ;04-07-1991 03:15:00
If the string can't be converted, then BadDate is set to true.
See Also: BadDate
Category: International Time
Timer : Number
Returns the system timer 32 bit value that is set to 0 at midnight and
is incremented 18.2 times a second.
Category: Time
TimeSeparator : String
Returns the time separator character from the country information.
See Also: DecimalSeparator DateSeparator CountryCode
Category: International Time
TimeString (Time) : String
Returns the time as a string in HH:MM:SS format. 24 hour. If no
parameter is passed, Now is assumed.
Example:
Writeln TimeString
;returns the time of Now as text
Writeln TimeString (Now + (5 * SecondsInHour))
;returns the time of 5 hours from now as text
Category: String Time
Computer Tyme * MarxMenu * Users Manual Page #245
-----------------------------------------------------------------
TMaxActiveTasks : Number
Returns the number of active tasks started under TaskMax.
Category: TaskMax
TMaxCreateTask (command string)
TMaxCreateTask creates a new task and executes it. You pass it a command
line just like you would use the EXECUTE program. Like the EXECUTE
program, if you use the COM or EXE extension then you won't load a
secondary COMMAND.COM and save yourself 5k of memory and gain some
speed. When the program exits that task is cleared.
The TaskID of the created task is returned in TMaxResult.
Example:
TMaxCreateTask 'DIR *.*'
See Also: TMaxReturnCount TMaxResult
Category: TaskMax
TMaxCut (TaskID)
Activates TaskMax data-cutting function.
See Also: TMaxPaste TMaxGetPasteBuffer TMaxSetPasteBuffer
Category: TaskMax
TMaxDeleteTask (TaskID)
Kills the task identified by TaskID.
See Also: TMaxTaskOpenFiles
Category: TaskMax
TMaxDirectSwitching (On/Off)
Turns On or Off the ability to use the direct switch keys without going
through the task manager menu. Default is On. By setting it to Off the
direct switch keys work normally. TaskMax sometimes conflicts with
applications when direct switching is On.
Example:
TMaxdirectSwitching Off
Computer Tyme * MarxMenu * Users Manual Page #246
-----------------------------------------------------------------
Category: TaskMax
TMaxEMSMemLim (Number)
This is a variable that can be either read or set to the maximum number
of bytes of EMS memory that each task can have. This prevents one task
from hogging up all the EMS. Setting this to 0 disables limiting.
Example:
TMaxEMSMemLim = 2000000 ;2 megs per task
Writeln TMaxEMSLim
Category: TaskMax
TMaxGetPasteBuffer (Array)
Reads the TaskMax paste buffer into an array of strings.
See Also: TMaxCut TMaxPaste TMaxSetPasteBuffer
Category: TaskMax
TMaxInstalled : Boolean
This function returns true if TaskMax is installed. Any other TaskMax
command produces a run-time error if used when TaskMax is not installed.
Example:
if not TMaxInstalled
Writeln 'This menu requires TaskMax to run!'
endif
Category: TaskMax
TMaxMaxTasks : Number
Returns the total number of tasks allowed by TaskMax. Default is 20.
Category: TaskMax
TMaxNameTask (Task,Name)
Normally TaskMax automatically names tasks according to what program is
running. TMaxNameTask allows you to override the default task name with
a task name of your choosing. The name is limited to 8 characters,
Example:
TMaxNameTask (2,'MYNAME') ;renames task 2
Computer Tyme * MarxMenu * Users Manual Page #247
-----------------------------------------------------------------
Category: TaskMax
TMaxPaste (TaskID)
Activates TaskMax data pasting function.
See Also: TMaxCut TMaxGetPasteBuffer TMaxSetPasteBuffer
Category: TaskMax
TMaxReadTaskInfo (2D Array)
Reads the task information table into a 2-dimensional array where the
first field is the task name and the second field is the TaskId number.
The TaskID number is used by all TMax commands that act on a single task
(TMaxDelete, TMaxSwitchTasks... ).
Example:
var Tasks
TMaxReadTaskInfo(Tasks)
Loop Tasks
Writeln Tasks[LoopIndex,1] ' ' Tasks[LoopIndex,2]
EndLoop
Category: TaskMax
TMaxResult : Number
TMaxResult is a variable containing return information that other TMax
command return or the result status of a TMax command.
Category: TaskMax
TMaxReturnCount
This variable sets the number of timer ticks (18.2 ticks per second)
that TMaxCreateTask will execute in a program before returning to the
original program. If it is set to 0 it will stay in the original
program. By setting TMaxReturnCount to a number other than 0 you can run
a program for a few seconds and come back. This is used to preload tasks
that you might later want to switch to.
Example:
TMaxReturnCount = 27 ;1.5 Seconds
TMaxCreateTask 'DM3.EXE' ;load a file manager
TMaxReturnCount = 0 ;set back to 0 for normal usage
See Also: TMaxCreateTask
Computer Tyme * MarxMenu * Users Manual Page #248
-----------------------------------------------------------------
Category: TaskMax
TMaxSetPasteBuffer (Array)
Sets the TaskMax paste buffer to the strings in array.
See Also: TMaxCut TMaxPaste TMaxGetPasteBuffer
Category: TaskMax
TMaxSwitchTasks (TaskID)
Switches the current task out and selects the task identified be TaskID.
Category: TaskMax
TMaxSwitchToManager
This command brings up the task manager the same way as if you had
pressed the hot key.
Category: TaskMax
TMaxTakeOver (On/Off)
This allows your MarxMenu program to become the task manager menu. When
the user presses the hot key to pop up the task switching menu it will
pop up your MarxMenu program instead. You can disable this by setting it
to Off.
Category: TaskMax
TMaxTaskOpenFiles (TaskID) : Number
Returns the number of open files a task has. You may want to test to see
if a task that open files before deleting the task.
Example:
if TMaxTaskOpenFiles (3) > 0
Writeln 'Task 3 has open files.'
endif
See Also: TMaxDeleteTask
Category: TaskMax
Computer Tyme * MarxMenu * Users Manual Page #249
-----------------------------------------------------------------
TMaxThisTask : Number
Returns the TaskID of the current task.
Category: TaskMax
TMaxVersion : Number
Returns the version number of TaskMax.
Category: TaskMax
Today : Date
Returns the current day as a date. The date returned has the time set to
midnight or 00:00:00. It can also be used to set the system date.
Read the current day;
X = Today
Set the system clock:
Today = TimeOf '08-19-91'
See Also: Tomorrow Now
Category: Time
Tomorrow : Time
Returns the time of the day after today at midnight.
See Also: Today Now
Category: Time
Tone (Frequency,Duration)
This command plays a note at Frequency cycles per second for a period of
Duration 1/18 of a second. The reason it is in 1/18 seconds is because
there is a standard interrupt that returns that time period. The IBM
series computers are not music oriented machines so don't throw away
your Compact Disk player.
The maximum duration is 255 1/18 of a second. Normally, MarxMenu will
create a break in between notes equal to 1/8 of the duration of the
note. If you want to eliminate the break and create a 'slur' (music
term), add 256 to the duration. This tells MarxMenu to connect the notes
without a break.
Computer Tyme * MarxMenu * Users Manual Page #250
-----------------------------------------------------------------
Category: Music
TotalDiskSpace (Drive) : Number
Returns total disk space in bytes.
Example:
Writeln (TotalDiskSpace 'C')
TotalDiskSpace only looks at the first character of the string for
the drive letter.
Category: System
TotalEMS : Number
Returns total EMS memory in bytes.
Example:
Writeln TotalEMS
Category: Memory
Trim (String or Array)
Trims white space from both ends of a string. White space is
blank characters and lower.
Example:
St = ' ABC '
Trim St ;St now is 'ABC'
When used with an array Trim removes blank lines from the beginning and
end of the array. It doesn't trim the elements of the array.
Category: String Array
TrimInputString (On/Off)
TrimInputString if set to On will cause blank characters to be trimmed
from the front and tail of a string read from the keyboard with Readln.
By default, TrimInputString is set to true.
See Also: Readln
Category: String
Computer Tyme * MarxMenu * Users Manual Page #251
-----------------------------------------------------------------
TrueName (String) : String
There is an undocumented feature of DOS called TRUENAME. It returns the
real name of a file or directory looking past such things as drive
mappings and Assigned or Substituted drives. On local drives you get the
drive and path where the file really is. On networks you get server and
volume information where the server name starts with a '\\'.
Example:
TrueName ('H:') ;returns \\TYME\SYS\HOME\MARC
See Also: CleanFileName
Category: String File
TSRs (Array)
TSRs returns a list of all TSRs in memory as well as the names of
pending batch files.
Example:
var TsrList
TSRs(TsrList)
Loop TsrList
Writeln TsrList[LoopIndex]
EndLoop
See Also: InMem
Category: Memory
UnBlank : Boolean
Unblank returns true if MarxMenu has determined that the screen blanker
should finish. Your screen blanker needs to call UnBlank to determine
when to unblank the screen.
Example:
while not UnBlank
<your screen blanker>
endwhile
You can also set UnBlank to true when you want to UnBlank the screen.
This can be used if you write your own screen blanker that is an
external program.
An example of writing your own screen blanker is included in the file
WORM.INC.
Computer Tyme * MarxMenu * Users Manual Page #252
-----------------------------------------------------------------
Example:
Procedure MyBlanker
Execute 'MYBLANK.EXE'
UnBlank = True
EndProc
See Also: BlankScreenProgram
Category: Display
UniqueFileName : String
Uses the create new file call to get a filename that is different than
any other filename. It is tied to the DOS call that is used to create a
unique filename according to the rules of your operating system.
Category: File String
Until
Conditional control.
Example:
Repeat
<statement>
<statement>
Until <condition>
See Also: Repeat.
Category: Conditional
UpperCase (String) : String
Return UpperCase of String including support for international
characters.
Example:
Name = UpperCase(Name)
See Also: LowerCase
Category: String International
Computer Tyme * MarxMenu * Users Manual Page #253
-----------------------------------------------------------------
UpperCaseOnly : Boolean
Setting UpperCaseOnly to On forces text entered with Readln or ReadKey
to upper case.
Example:
UpperCaseOnly On
See Also: Readln
Category: String
UseArrows
UseArrows tells MarxMenu that the selection will be made by moving an
inverse video bar over the selections. No parameters are required for
this command to work. It will pick the first line with a capital letter
as the first menu selection. All text in the window must be indented at
least one space and there must be one space between the end of the line
and the right wall of the window. Multiple items on the same line must
be separated by two or more spaces.
The OnKey selection is triggered by either the first capital letter in
the selection or by a number from 0 - 9 or some punctuation characters.
This number or letter will be a different color if you use the CapsColor
command. (See Also: PULL.MNU for an example).
UseArrows Off will disable this feature.
See Also: ReadKey
Category: Display
UseCommand (On/Off)
Used with Execute. UseCommand will load COMMAND.COM before running the
specified program. Its not as fast, because the system has to find and
load COMMAND.COM, then the specified program. The advantage is if
COMMAND.COM is loaded, it will allow you to run batch files and internal
DOS commands. It also doesn't require you to specify the COM or EXE
extension.
Example:
OnKey 'D'
|UseCommand On
|Execute 'DM'
The default is Off.
Computer Tyme * MarxMenu * Users Manual Page #254
-----------------------------------------------------------------
See Also: Execute
Category: Execution
UsedDiskSpace (Drive) : Number
Returns used disk space in bytes.
Example:
Writeln (UsedDiskSpace 'C')
UsedDiskSpace only looks at the first character of the string for the
drive letter.
Category: System
UseNovPassword : Boolean
If UseNovPassword is set to true then the screen blanker will require
that the user type his Novell password to unblank the screen. Full
Novell security and intruder detection is active here. If Novell's
intruder detection is active, then if an intruder fails to type in the
password after a number of attempts, then Netware will not accept the
correct password until intruder detection allows it.
If you don't know what intruder detection is, read the Netware manuals
on the subject. It is something you should use.
Category: Novell
Value (String) : Number
Converts String to Number. Leading $ indicates Hex.
Example:
Value '5' ;returns 5
See Also: Str
Category: String Math Real
Var
In MarxMenu all variables must be declared before they can be
referenced. The VAR command is used to declare variables.
Example:
var X,Y,Z
var
X = 5
Y = 6
Computer Tyme * MarxMenu * Users Manual Page #255
-----------------------------------------------------------------
See Also: Constant Shared Qualifier
Category: Variable
VarType (Variable) : String
VarType returns the type of data contained in a variable. Types returned
include the following:
NUL
NUMBER
REAL
STRING
ARRAY
FILE
POINTER
PROCEDURE
UNKNOWN
Category: Variable
VCPIInstalled : Boolean
Returns True if VCPI services are installed.
See Also: VCPIVersion
Category: System
VCPIVersion : String
VCPIVersion returns the version of the VCPI driver you are using. If
VCPI isn't present it returns an empty string.
See Also: VCPIInstalled
Category: System
VideoMode : Number
Returns Current Video Mode.
Example:
Writeln VideoMode
Category: Video
Computer Tyme * MarxMenu * Users Manual Page #256
-----------------------------------------------------------------
VideoPage : Number
Returns Current Video Page.
Category: Video
ViewArray (Array)
Allows you to view an array of strings in the current window. Works just
like ViewTextFile.
Example:
var New
ReadTextFile ('MARXREAD.ME',New)
DrawBox 1 2 80 23
ViewArray New
See Also: ViewTextFile
Category: Display Array
ViewTextFile (Name)
This command lets you view a text file in the current window.
Example:
DrawBox 1 2 80 23
ViewTextFile 'MARXREAD.ME'
See Also: ViewArrayFile
Category: Display File
VinCheckService (Service) : Number
Returns information about the requested service.
Services:
1 - Communications
2 - Primary 3270 Emulation ID
3 - Async Terminal Emulation
4 - File Deflection
5 - BPS
6 - Undocumented
7 - StreetTalk
8 - Environment
9 - NetBios
10 - Secondary 3270 Emulation ID
11 - Semaphore
12 - 3270 Emulation Active Status
13 - 3270 Keyboard Interrupt Simulator
14 - Advanced 3270 SNA
15 - Undocumented
16 - Undocumented
Computer Tyme * MarxMenu * Users Manual Page #257
-----------------------------------------------------------------
Return Codes:
0 - Service is Installed
1 - Service is not Installed
2 - Invalid Service Number
Category: Vines
VinesInt : Number
Returns the interrupt number the Vines software is servicing.
Category: Vines
VinesLoaded : Boolean
VinesLoaded returns true if the Vines shell is loaded.
Category: Vines
VinUserName : String
Returns the StreetTalk name of the person who is logged in.
Category: Vines
VinSerialNumber (Drive) : Number
Returns the Vines serial number on the server that the drive letter
references.
Example:
Writeln VinSerialNumber ('Z')
Category: Vines
Volume (Drive)
Returns the volume label of the specified drive.
Example:
Writeln Volume 'C' ;volume label on drive C
Category: System
Computer Tyme * MarxMenu * Users Manual Page #258
-----------------------------------------------------------------
VT100mode (On/Off)
There are some differeences between ANSI and VT100 codes. When VT100mode
is on the AnsiWindows respond to VT100 sequences.
See Also: AnsiWindows
Category: Modem
Wait (Number)
Delay for a number of 1/100 seconds. Wait 250 delays 2 1/2 seconds.
If you are running a multi-tasker like Windows 3 or DesqView, and the
delay is over 1/4 second, MarxMenu will release time slices back to DOS
and not bog down the CPU power on long waits. MarxMenu also releases CPU
cycles while idle at the keyboard.
Example:
Wait 300 ;3 second delay
See Also: WaitOrKbdReady
Category: Misc
WaitOrKbdReady (Number)
This command is just like the WAIT command except the wait is aborted by
pressing any key. Time to wait is in hundredths of a second. This
command is useful when using MarxMenu to write a running demo.
Example:
WaitOrKbdReady 300 ;3 second delay or until KeyPress
See Also: Wait
Category: Keyboard
WhereX : Number
Returns the horizontal position of the cursor within the current window.
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #259
-----------------------------------------------------------------
WhereXAbs : Number
Returns the horizontal screen position of the cursor.
Category: Display
WhereY : Number
Returns the vertical position of the cursor within the current window.
WhereYAbs : Number
Returns the vertical screen position of the cursor.
Category: Display
While
Used for program control. Usage:
WHILE (condition)
(statement)
(statement)
ENDWHILE
Execution stays in the while loop as long as the condition is true.
See Also: EndWhile
Category: Conditional
WholeFileNames (On/Off)
Controls if ReadDirectory will return the whole name and path or just
the filename part.
Example:
Var X
WholeFileNames Off ;Just filename, no paths!
ReadDirectory('*.MNU',X)
Loop X
Execute ('COPY ' + X[LoopIndex] + ' A:')
EndLoop
See Also: ReadDirectory
Category: File Directory
Computer Tyme * MarxMenu * Users Manual Page #260
-----------------------------------------------------------------
Window (X,Y,Width,Height)
Window changes the size of the active area of the screen. It can be used
to either reduce or expand where text can be written.
See Also: DrawBox
Category: Display
WindowHeight : Number
Returns number of rows in current window.
Category: Display
WindowWidth : Number
Returns number of columns in current window.
Category: Display
WinX : Number
Returns the horizontal location of the left hand corner of the window.
See Also: WinY
Category: Display
WinY : Number
Returns the vertical location of the left-hand corner of the window.
See Also: WinX
Category: Display
Within (Start,End) : Boolean
Within returns true if a value is within the range from Start to End.
Within works with numbers and strings.
Example:
Within (Start,End) : Boolean
Within returns True if a value is within the range from Start to End.
Within works with numbers and strings.
Example:
if X within(5,7) then Write 'X is Within 5 to 7'
if not (Ch within('A','Z')) Write 'Lower Case'
Computer Tyme * MarxMenu * Users Manual Page #261
-----------------------------------------------------------------
Category: Misc
WordStarKeys (On/Off)
In the early days of MarxMenu I mapped many of the cursor movement keys
to match the WordStar key strokes. Now you can turn this off to get the
real scan codes from the arrow keys.
See Also: Readln
Category: String
WorkString : String
WorkString is a MarxMenu variable that contains the string that Readln
is editing. This string can be accessed by KeyEvent routines so that a
KeyEvent procedure can set what is being entered.
Example:
WorkString = PickOne(List)
See Also: KeyEvent
Category: String
Write (String)
Writes (String) on the screen at the current cursor position.
Example:
Write ' - Heading - '
Category: Display
WriteAscTextFile (File,2DArray)
WriteAscTextFile writes a 2-dimensional array to a comma delimited
ascii text file.
Category: File
WriteCenter (String)
Writes (String) centered in current window.
Category: Display
Computer Tyme * MarxMenu * Users Manual Page #262
-----------------------------------------------------------------
WriteError (String)
This command works just like Write except that it writes to the DOS
error device handle. This can be used to put messages on the screen when
the output is redirected to a file.
See Also: WritelnError
Category: Display
WriteFileBlock (Name,Offset,Size,Segment)
WriteFileBlock writes disk file Name starting at byte Offset for Size
bytes from memory buffer Segment. It is intended to write any kind of
file. If the file doesn't exist, it is created.
The maximum value for Size is 65504. The segment must be as large as the
number of bytes you are writing.
See Also: ReadFileBlock GetMem FreeMem
Category: File Memory
Writeln (String)
Writes (String) on the screen followed by a CR-LF (carriage
return-line feed).
Example:
Writeln 'The time is: ' TimeString
Category: Display
WritelnAsc (File,Array)
WritelnAsc writes one line to the end of a comma delimited ascii text
file. Each element of the array becomes one field of that line.
Example:
var A
A[1] = 'MARC PERKEL'
A[2] = 'ONION'
A[3] = 37
WritelnAsc('TEST.TXT',A)
;appends "MARC PERKEL","ONION",37 to file TEST.TXT
Category: File
Computer Tyme * MarxMenu * Users Manual Page #263
-----------------------------------------------------------------
WritelnError (String)
This command works just like Writeln except that it writes to the DOS
error device handle. This can be used to put messages on the screen when
the output is redirected to a file.
See Also: WriteError
Category: Display
WriteTextFile (FileName,Array)
This command writes a string array to a text file. Do not use FileCreate
or any other file commands with this. This command does it all.
Example:
var X
ReadTextFile('MARXREAD.ME',X)
WriteTextFile('A:MARXREAD.ME',X) ;copies file to A:
See Also: ReadTextFile
Category: File Array
WriteVertical (String)
Writes (String) vertically on the screen from the current cursor
position.
Example:
WriteVertical( 'Hello' )
;This would display
H
e
l
l
o
Category: Display
XmsInstalled : Boolean
Returns True if XMS memory manager is installed.
See Also: XmsVersion
Category: System
Computer Tyme * MarxMenu * Users Manual Page #264
-----------------------------------------------------------------
XmsVersion : String
XmsVersion returns the version of the XMS driver you are using. If XMS
isn't present it returns an empty string.
See Also: XmsInstalled
Category: System
Xor : Operator
Returns logical Xor if operators are boolean; or bitwise Xor if
operators are numeric.
Xor (exclusive or) means one or the other but not both can be true.
Example:
A = True
B = False
A Xor B ;returns true
See Also: And Or Not
Category: Math Boolean
Year : Number
Returns current Year.
Example:
Writeln Year ;returns 1993
Category: Time
YearOf (Date) : Number
Returns the year of a date. If Date is passed as a string it is
converted automatically.
Example:
Writeln YearOf Today ;returns 1993
See Also: TimeOf BadDate
Category: Time
Computer Tyme * MarxMenu * Users Manual Page #265
-----------------------------------------------------------------
STRING CONSTANTS
F1 = #0#59 SF1 = #0#84 CF1 = #0#94 AF1 = #0#104
F2 = #0#60 SF2 = #0#85 CF2 = #0#95 AF2 = #0#105
F3 = #0#61 SF3 = #0#86 CF3 = #0#96 AF3 = #0#106
F4 = #0#62 SF4 = #0#87 CF4 = #0#97 AF4 = #0#107
F5 = #0#63 SF5 = #0#88 CF5 = #0#98 AF5 = #0#108
F6 = #0#64 SF6 = #0#89 CF6 = #0#99 AF6 = #0#109
F7 = #0#65 SF7 = #0#90 CF7 = #0#100 AF7 = #0#110
F8 = #0#66 SF8 = #0#91 CF8 = #0#101 AF8 = #0#111
F9 = #0#67 SF9 = #0#92 CF9 = #0#102 AF9 = #0#112
F10 = #0#68 SF10 = #0#93 CF10 = #0#103 AF10 = #0#113
F11 = #0#133 SF11 = #0#135 CF11 = #0#137 AF11 = #0#139
F12 = #0#134 SF12 = #0#136 CF12 = #0#138 AF12 = #0#140
ALT1 = #0#120 BKSP = #8
ALT2 = #0#121 CR = #13
ALT3 = #0#122 CRLF = #13#10
ALT4 = #0#123 ESC = #27
ALT5 = #0#124 FF = #12
ALT6 = #0#125 LF = #10
ALT7 = #0#126
ALT8 = #0#127
ALT9 = #0#128
ALT0 = #0#129
Key Scan WordStar
----------------------------------
UpArrow = #0#72 ^E
DownArrow = #0#80 ^X
LeftArrow = #0#75 ^S
RightArrow = #0#77 ^D
HomeKey = #0#71 ^W
EndKey = #0#79 ^Z
CtrlLeftArrow = #0#115 ^A
CtrlRightArrow = #0#116 ^F
PgUpKey = #0#73 ^R
PgDnKey = #0#81 ^C
InsKey = #0#82 ^V
DelKey = #0#83 ^G
Category: Constants
Computer Tyme * MarxMenu * Users Manual Page #266
-----------------------------------------------------------------
TIME AND DATE CONSTANTS
Jan = 1 Sun = 0
Feb = 2 Mon = 1
Mar = 3 Tue = 2
Apr = 4 Wed = 3
May = 5 Thu = 4
Jun = 6 Fri = 5
Jul = 7 Sat = 6
Aug = 8
Sep = 9 SecondsInHour = 3600
Oct = 10 SecondsInDay = 86400
Nov = 11
Dec = 12
Category: Constants
VIDEO CONSTANTS
Video Modes: Display Types:
BW40 = 0 0 = HercMono
CO40 = 1 1 = CGA
BW80 = 2 2 = MCGA
CO50 = 3 3 = EGA
MONO = 7 4 = VGA
Category: Constants
COLOR CONSTANTS
Black = 0 DGrey = 8
Blue = 1 LBlue = 9
Green = 2 LGreen = 10
Cyan = 3 LCyan = 11
Red = 4 LRed = 12
Magenta = 5 LMagenta = 13
Brown = 6 Yellow = 14
Grey = 7 White = 15
Category: Constants
BOOLEAN CONSTANTS
True Yes On
False No Off
Category: Constants
Computer Tyme * MarxMenu * Users Manual Page #267
-----------------------------------------------------------------